diff --git a/code/scripts/generate_plots.py b/code/scripts/generate_plots.py index ac928d5..9db0cbc 100644 --- a/code/scripts/generate_plots.py +++ b/code/scripts/generate_plots.py @@ -1,32 +1,32 @@ import os import matplotlib.pyplot as plt import pandas as pd import plots.plot_categories as plot_categories import plots.plot_fossil_fuel_industry as plot_fossil_fuel_industry import plots.plot_government as plot_government import plots.plot_experience as plot_experience import plots.plot_missing_participants as plot_missing_participants import plots.plot_gender_rate as plot_gender_rate import plots.plot_delegation_sizes as plot_delegation_sizes import plots.plot_overall_experience_distr as plot_overall_experience_distr import plots.plot_delegation_exp as plot_delegation_exp import plots.plot_intervention_distr as plot_intervention_distr import plots.plot_detailed_experience as plot_detailed_experience import plots.plot_participant_graph as plot_participant_graph import plots.plot_RMSE_results as plot_RMSE_results -plot_RMSE_results.plot({"Baseline Zero": 9.03, "Ridge regression": 5.01}) +plot_RMSE_results.plot({"Baseline Zero": 9.54, "Baseline Average": 5.02, "Ridge Regression": 5.01, "RR + Log. Transformation": 5.6, "Combined Model": 5.01}) plot_intervention_distr.plot("../data/data_regression/dataset_interventions.csv") plot_fossil_fuel_industry.plot("../results/complete_dataset.csv") plot_participant_graph.plot("../results/experience_dict_def.txt") plot_gender_rate.plot("../results/complete_dataset.csv") plot_detailed_experience.plot("../results/complete_dataset_experience-def.csv") plot_experience.plot("../results/complete_dataset_experience-def.csv") plot_government.plot("../results/complete_dataset.csv") plot_categories.plot("../results/participants-csv/participants_") plot_missing_participants.plot("../results/participants-csv/participants_cop") plot_delegation_exp.plot("../results/complete_dataset_experience-def.csv") plot_overall_experience_distr.plot("../results/complete_dataset_experience-2.csv") plot_delegation_sizes.plot("../results/complete_dataset.csv") diff --git a/code/scripts/plots/plot_RMSE_results.py b/code/scripts/plots/plot_RMSE_results.py new file mode 100644 index 0000000..fee0457 --- /dev/null +++ b/code/scripts/plots/plot_RMSE_results.py @@ -0,0 +1,14 @@ +import matplotlib.pyplot as plt + + +def plot(data): + xs = [] + heights = [] + for x, h in data.items(): + xs.append(x) + heights.append(h) + + plt.bar(xs, heights) + plt.ylabel("RMSE") + plt.title("RMSE on the test samples of the different models") + plt.show()