Skip to content

Commit

Permalink
Move candidate plot legend back to right side
Browse files Browse the repository at this point in the history
cthoyt committed Apr 4, 2022
1 parent 75b142d commit 17e9489
Showing 4 changed files with 219 additions and 232 deletions.
Binary file modified charts/candidate_plot.pdf
Binary file not shown.
Binary file modified charts/candidate_plot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
433 changes: 209 additions & 224 deletions charts/candidate_plot.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 10 additions & 8 deletions scripts/num_candidate_plots.py
Original file line number Diff line number Diff line change
@@ -30,6 +30,7 @@ def main(
min_log10: int = 0,
max_log10: int = 6,
points: int = 40,
legend_bottom: bool = False
):
sizes = np.logspace(min_log10, max_log10, num=points).astype(int)

@@ -77,14 +78,15 @@ def main(
aspect=1.6,
)
grid.set(xscale="log", yscale="log", ylabel="Value", xlabel="Number of Candidates")
sns.move_legend(
grid,
"lower center",
bbox_to_anchor=(0.40, -0.175),
ncol=3,
title="Metric",
frameon=True,
)
if legend_bottom:
sns.move_legend(
grid,
"lower center",
bbox_to_anchor=(0.40, -0.175),
ncol=3,
title="Metric",
frameon=True,
)
grid.tight_layout()
grid.savefig(CHART_STUB.with_suffix(".png"), dpi=300)
grid.savefig(CHART_STUB.with_suffix(".svg"))

0 comments on commit 17e9489

Please sign in to comment.