In [1]:
from ahh import exp, vis
import matplotlib.pyplot as plt
import pandas as pd
In [2]:
x = pd.date_range('2016-01-01', '2017-02-01', freq='7D')
y = exp.arr_1d(len(x), y=True)
In [3]:
vis.plot_line(x, y) # automatically sets date labels intelligently
Out[3]:
In [4]:
vis.plot_bar(x, y) # works for other types of plots as well
Out[4]:
In [5]:
vis.plot_scatter(x, y) # works for other types of plots as well
Out[5]:
In [6]:
x = pd.date_range('2016-01-01', '2016-05-01', freq='7D') # works for different time periods as well
y = exp.arr_1d(len(x), y=True)
vis.plot_line(x, y) # automatically sets date labels intelligently
Out[6]:
In [7]:
x = pd.date_range('2016-01-01', '2016-8-01', freq='7D') # works for different time periods as well
y = exp.arr_1d(len(x), y=True)
vis.plot_line(x, y) # automatically sets date labels intelligently
Out[7]:
In [8]:
x = pd.date_range('2016-01-01', '2016-2-25', freq='3D') # works for different time periods as well
y = exp.arr_1d(len(x), y=True)
vis.plot_line(x, y) # automatically sets date labels intelligently
Out[8]:
In [9]:
x = pd.date_range('2016-01-01', '2016-1-4', freq='8H') # works for different time periods as well
y = exp.arr_1d(len(x), y=True)
vis.plot_line(x, y) # automatically sets date labels intelligently
Out[9]:
In [10]:
x = pd.date_range('2016-01-01', '2016-1-2', freq='1H') # works for different time periods as well
y = exp.arr_1d(len(x), y=True)
vis.plot_line(x, y) # automatically sets date labels intelligently
Out[10]:
In [ ]: