Follow-up from "add plotly plotter"
The following discussion from !294 (merged) should be addressed:
-
@jbweston started a discussion: (+3 comments) AFAICT there is a lot of boilerplate shared between
_plot_plotly
(lines 977-1101) and_plot_matplotlib
(lines 1307-1461).We should try to factor out this boilerplate. AFAICT the boilerplate is exact copy/paste except for the handling of
dim=3
and the handling ofunit
.The boilerplate essentially just normalizes input parameters (
site_size
,site_color
, ...) or sets up extra variables (sites
,lead_sites_slcs
, ...). We can refactor the boilerplate intoplot
and just pass these extra variables to the_plot_*
functions.