In [1]:
from ahh import vis

In [3]:
percentages = [96, 90, 92, 93, 94, 75, 65, 85, 85, 80, 81, 80, 65, 20, 30, 45, 10, 10, 5, 5, 0, 0, 0] # make up y

vis.plot_hist(percentages, # just input your data and it'll intelligently figure out the bins
                   ylabel='Count', xlabel='Percentages', title='Automatic Bins hist')



In [4]:
bins = [0, 20, 40, 60, 80, 100]
vis.plot_hist(bins, percentages, # or input your own bins
                   ylabel='Count', xlabel='Percentages', title='Selected Bins hist')



In [5]:
vis.plot_hist(percentages, ptype='scatter', norm=True, # create PDF
                   ylabel='Frequency', xlabel='Percentages', title='Automatic PDF')



In [6]:
vis.plot_hist(percentages, ptype='line', norm=True, cumsum=True, # create CDF
                   ylabel='Frequency', xlabel='Percentages', title='Automatic CDF')



In [7]:
fruits = ['banana', 'banana', 'apple', 'orange', 'orange', 'orange', 'avocado', 'avocado', 'pear', 'cloud'] + ['test'] * 10

vis.plot_hist(fruits, # can also handle text
                   xlabel='Words', ylabel='Count', title='Text hist')



In [ ]:


In [ ]: