本文整理匯總了Python中pandas.tests.plotting.common.TestPlotBase.setup_method方法的典型用法代碼示例。如果您正苦於以下問題:Python TestPlotBase.setup_method方法的具體用法?Python TestPlotBase.setup_method怎麽用?Python TestPlotBase.setup_method使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類pandas.tests.plotting.common.TestPlotBase
的用法示例。
在下文中一共展示了TestPlotBase.setup_method方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: setup_method
# 需要導入模塊: from pandas.tests.plotting.common import TestPlotBase [as 別名]
# 或者: from pandas.tests.plotting.common.TestPlotBase import setup_method [as 別名]
def setup_method(self, method):
TestPlotBase.setup_method(self, method)
import matplotlib as mpl
mpl.rcdefaults()
self.ts = tm.makeTimeSeries()
self.ts.name = 'ts'
示例2: setup_method
# 需要導入模塊: from pandas.tests.plotting.common import TestPlotBase [as 別名]
# 或者: from pandas.tests.plotting.common.TestPlotBase import setup_method [as 別名]
def setup_method(self, method):
TestPlotBase.setup_method(self, method)
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'
示例3: setup_method
# 需要導入模塊: from pandas.tests.plotting.common import TestPlotBase [as 別名]
# 或者: from pandas.tests.plotting.common.TestPlotBase import setup_method [as 別名]
def setup_method(self, method):
TestPlotBase.setup_method(self, method)
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]