本文整理汇总了Python中pandas.tests.plotting.common.TestPlotBase.setUp方法的典型用法代码示例。如果您正苦于以下问题:Python TestPlotBase.setUp方法的具体用法?Python TestPlotBase.setUp怎么用?Python TestPlotBase.setUp使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类pandas.tests.plotting.common.TestPlotBase
的用法示例。
在下文中一共展示了TestPlotBase.setUp方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: setUp
# 需要导入模块: from pandas.tests.plotting.common import TestPlotBase [as 别名]
# 或者: from pandas.tests.plotting.common.TestPlotBase import setUp [as 别名]
def setUp(self):
TestPlotBase.setUp(self)
import matplotlib as mpl
mpl.rcdefaults()
self.ts = tm.makeTimeSeries()
self.ts.name = 'ts'
示例2: setUp
# 需要导入模块: from pandas.tests.plotting.common import TestPlotBase [as 别名]
# 或者: from pandas.tests.plotting.common.TestPlotBase import setUp [as 别名]
def setUp(self):
TestPlotBase.setUp(self)
freq = ["S", "T", "H", "D", "W", "M", "Q", "A"]
idx = [period_range("12/31/1999", freq=x, periods=100) for x in freq]
self.period_ser = [Series(np.random.randn(len(x)), x) for x in idx]
self.period_df = [DataFrame(np.random.randn(len(x), 3), index=x, columns=["A", "B", "C"]) for x in idx]
freq = ["S", "T", "H", "D", "W", "M", "Q-DEC", "A", "1B30Min"]
idx = [date_range("12/31/1999", freq=x, periods=100) for x in freq]
self.datetime_ser = [Series(np.random.randn(len(x)), x) for x in idx]
self.datetime_df = [DataFrame(np.random.randn(len(x), 3), index=x, columns=["A", "B", "C"]) for x in idx]
示例3: setUp
# 需要导入模块: from pandas.tests.plotting.common import TestPlotBase [as 别名]
# 或者: from pandas.tests.plotting.common.TestPlotBase import setUp [as 别名]
def setUp(self):
TestPlotBase.setUp(self)
import matplotlib as mpl
mpl.rcdefaults()
self.ts = tm.makeTimeSeries()
self.ts.name = 'ts'
self.series = tm.makeStringSeries()
self.series.name = 'series'
self.iseries = tm.makePeriodSeries()
self.iseries.name = 'iseries'
示例4: setUp
# 需要导入模块: from pandas.tests.plotting.common import TestPlotBase [as 别名]
# 或者: from pandas.tests.plotting.common.TestPlotBase import setUp [as 别名]
def setUp(self):
TestPlotBase.setUp(self)
freq = ['S', 'T', 'H', 'D', 'W', 'M', 'Q', 'A']
idx = [period_range('12/31/1999', freq=x, periods=100) for x in freq]
self.period_ser = [Series(np.random.randn(len(x)), x) for x in idx]
self.period_df = [DataFrame(np.random.randn(len(x), 3), index=x,
columns=['A', 'B', 'C'])
for x in idx]
freq = ['S', 'T', 'H', 'D', 'W', 'M', 'Q-DEC', 'A', '1B30Min']
idx = [date_range('12/31/1999', freq=x, periods=100) for x in freq]
self.datetime_ser = [Series(np.random.randn(len(x)), x) for x in idx]
self.datetime_df = [DataFrame(np.random.randn(len(x), 3), index=x,
columns=['A', 'B', 'C'])
for x in idx]