bigframes.pandas.DataFrame.itertuples#
- DataFrame.itertuples(index: bool = True, name: str | None = 'Pandas') Iterable[tuple[Any, ...]][source]#
Iterate over DataFrame rows as namedtuples.
Examples:
>>> df = bpd.DataFrame({ ... 'A': [1, 2, 3], ... 'B': [4, 5, 6], ... }) >>> next(df.itertuples(name="Pair")) Pair(Index=np.int64(0), A=np.int64(1), B=np.int64(4))
- Parameters:
- Returns:
An object to iterate over namedtuples for each row in the DataFrame with the first field possibly being the index and following fields being the column values.
- Return type:
Iterable[Tuple]