MCPcopy Index your code
hub / github.com/pydata/xarray / df

Method df

xarray/tests/test_pandas_to_xarray.py:113–125  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

111class TestDataFrameToXArray:
112 @pytest.fixture
113 def df(self):
114 return DataFrame(
115 {
116 "a": list("abcd"),
117 "b": list(range(1, 5)),
118 "c": np.arange(3, 7).astype("u1"),
119 "d": np.arange(4.0, 8.0, dtype="float64"),
120 "e": [True, False, True, False],
121 "f": Categorical(list("abcd")),
122 "g": date_range("20130101", periods=4),
123 "h": date_range("20130101", periods=4, tz="US/Eastern"),
124 }
125 )
126
127 def test_to_xarray_index_types(self, index_flat, df):
128 index = index_flat

Callers

nothing calls this directly

Calls 3

date_rangeFunction · 0.85
arangeMethod · 0.80
astypeMethod · 0.45

Tested by

no test coverage detected