print variances when plotting evaluation variance benchmark

This commit is contained in:
Christoffer Müller Madsen 2018-03-26 17:06:12 +02:00
parent 4c43bf19a3
commit 9b2bbfb4d1
Signed by: christoffer
GPG Key ID: 337BA5A95E686EFD

11
plot.py
View File

@ -17,13 +17,18 @@ def plot_bench(data_path):
df = pd.read_csv(data_path, sep=";",
names=bench_headers, index_col=[0,1,2])
for method_label in df.index.levels[0]:
cur_df = df.loc[method_label]
plot = df[['mean']].loc['pubeval'].unstack().T.plot.box()
df_prime = df[['mean']].loc[method_label].unstack().T
plot = df_prime.plot.box()
plot.set_title("Evaluation variance, {}".format(method_label))
plot.set_xlabel("Sample count")
plot.set_ylabel("Mean score")
plt.show(plot.figure)
del cur_df, plot
# for later use:
variances = df_prime.var()
print(variances)
del df_prime, plot, variances
def dataframes(model_name):
def df_timestamp_to_datetime(df):