In [1]:
# Basic setup for displaying bokeh plots in jupyter.
import bokeh
from bokeh.plotting import figure
from bokeh.io import output_notebook, show
output_notebook()
In [2]:
# NumPy imports.
import numpy as np
import cPickle as pickle
import os
cwd = os.getcwd()
print(cwd)
In [3]:
# Load parsed data (NumPy array).
array = pickle.load(open('2018-03-27-10-49-30_array.p', 'rb'))
print(array.shape)
In [4]:
array_warehouse = pickle.load(open('wh-2018-05-02-22-27-35-098526_array.p','rb'))
print(array_warehouse.shape)
In [5]:
# Plot.
p = figure(width=500,
height=500,
x_axis_label="Total # of Targets Retrieved per Analysis",
y_axis_label="Runtime (seconds)",
title="C. Overall Runtimes for Fisher's Analysis",
)
p.axis.major_label_text_font_size="12pt"
p.axis.axis_label_text_font='12pt'
p.circle(array[0],array[1], size=1, color="darkslateblue", alpha=0.1)
p.circle(array_warehouse[0],array_warehouse[1], size=1, color="red", alpha=0.9)
show(p)
In [7]:
import numpy as np
l = pickle.load(open('api-2018-05-03-10-22-35-670254_list.p', 'rb'))
# Plot a histogram of the targets.
x = np.array(l)
print(x.mean())
hist, edges = np.histogram(x, density=True, bins=50)
p1 = figure(title="",tools="save",)
p1.quad(top=hist, bottom=0, left=edges[:-1], right=edges[1:],
fill_color="blue", line_color="#033649", alpha=0.5)
show(p1)
In [ ]: