MCPcopy Create free account
hub / github.com/apache/arrow / select_columns

Method select_columns

python/pyarrow/interchange/dataframe.py:158–164  ·  view source on GitHub ↗

Create a new DataFrame by selecting a subset of columns by index.

(self, indices: Sequence[int])

Source from the content-addressed store, hash-verified

156 ]
157
158 def select_columns(self, indices: Sequence[int]) -> _PyArrowDataFrame:
159 """
160 Create a new DataFrame by selecting a subset of columns by index.
161 """
162 return _PyArrowDataFrame(
163 self._df.select(list(indices)), self._nan_as_null, self._allow_copy
164 )
165
166 def select_columns_by_name(
167 self, names: Sequence[str]

Callers 1

test_dataframeFunction · 0.45

Calls 3

_PyArrowDataFrameClass · 0.85
listFunction · 0.85
selectMethod · 0.45

Tested by 1

test_dataframeFunction · 0.36