Skip to content

Commit

Permalink
change connected dots to a scatter plot
Browse files Browse the repository at this point in the history
We could get a scatter plot by altering the `format` passed to `plot` but `scatter` has nice defaults.
  • Loading branch information
tomeichlersmith committed Aug 29, 2024
1 parent 8b49d02 commit 117acb4
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions Validation/src/Validation/_differ.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,12 +137,13 @@ def plot1d(self, column, xlabel,
denominator, bins, _denominator_art = raw_histograms[0]
bin_centers = (bins[1:]+bins[:-1])/2
for values, _bins, art in raw_histograms[1:]:
ratio_ax.plot(
ratio_ax.scatter(
bin_centers,
values/denominator,
color = art[0].get_edgecolor()
)


ratio_ax.set_ylabel('Ratio')
ratio_ax.set_xlabel(xlabel)
if tick_labels is not None:
ratio_ax.set_xticks((bins[1:]+bins[:-1])/2)
Expand Down

0 comments on commit 117acb4

Please sign in to comment.