getdist.plots.GetDistPlotSettings

class getdist.plots.GetDistPlotSettings(subplot_size_inch=2, fig_width_inch=None)[source]

Settings class (colors, sizes, font, styles etc.)

Variables:
  • alpha_factor_contour_lines – alpha factor for adding contour lines between filled contours
  • alpha_filled_add – alpha for adding filled contours to a plot
  • auto_ticks – use matplotlib 2+ auto tick spacing/numbers (default: False, use own heuristics)
  • axis_marker_color – The color for a marker
  • axis_marker_ls – The line style for a marker
  • axis_marker_lw – The line width for a marker
  • colorbar_label_pad – padding for the colorbar labels
  • colorbar_label_rotation – angle to rotate colorbar label (set to zero if -90 default gives layout problem)
  • colorbar_rotation – angle to rotate colorbar tick labels
  • colormap – a Matplotlib color map for shading
  • colormap_scatter

    a Matplotlib color map for 3D plots

  • default_dash_styles – dict mapping line styles to detailed dash styles, default: {‘–’: (3, 2), ‘-.’: (4, 1, 1, 1)}
  • fig_width_inch – The width of the figure in inches
  • figure_legend_frame – draw box around figure legend
  • figure_legend_loc – The location for the figure legend
  • figure_legend_ncol – number of columns for figure legend
  • legend_fontsize – The font size for the legend
  • legend_frac_subplot_line – fraction of _subplot size to use per line for spacing figure legend
  • legend_frac_subplot_margin – fraction of _subplot size to use for spacing figure legend above plots
  • legend_frame – draw box around legend
  • legend_loc – The location for the legend
  • legend_position_config – recipe for positioning figure border (default 1)
  • legend_rect_border – whether to have black border around solid color boxes in legends
  • line_labels – True if you want to automatically add legends when adding more than one line to subplots
  • lineM – list of default line styles/colors ([‘-k’,’-r’...])
  • no_triangle_axis_labels – whether subplots in triangle plots should show axis labels if not at the edge
  • norm_prob_label – label for the y axis in normalized 1D density plots
  • num_plot_contours – number of contours to plot in 2D plots (up to number of contours in analysis settings)
  • num_shades – number of distinct colors to use for shading shaded 2D plots
  • param_names_for_labels – file name of .paramnames file to use for overriding parameter labels for plotting
  • plot_args – dict, or list of dicts, giving settings like color, ls, alpha, etc. to apply for a plot or each line added
  • plot_meanlikes – include mean likelihood lines in 1D plots
  • prob_label – label for the y axis in unnormalized 1D density plots
  • prob_y_ticks – show ticks on y axis for 1D density plots
  • progress – write out some status
  • shade_level_scale – shading contour colors are put at [0:1:spacing]**shade_level_scale
  • shade_meanlikes – 2D shading uses mean likelihoods rather than marginalized density
  • solid_colors – List of default colors for filled 2D plots. Each element is either a color, or a tuple of values for different contour levels.
  • solid_contour_palefactor – factor by which to make 2D outer filled contours paler when only specifying one contour colour
  • thin_long_subplot_ticks – if auto_tick=False, whether to thin out tick labels where they are long to try to prevent overlap (default: True)
  • tick_prune – None, ‘upper’ or ‘lower’ to prune ticks
  • tight_gap_fraction – fraction of plot width for closest tick to the edge
  • tight_layout – use tight_layout to lay out and remove white space
  • x_label_rotation – The rotation for the x label in degrees.

If fig_width_inch set, fixed setting for fixed total figure size in inches. Otherwise use subplot_size_inch to determine default font sizes etc., and figure will then be as wide as necessary to show all subplots at specified size.

Parameters:
  • subplot_size_inch – Determines the size of subplots, and hence default font sizes
  • fig_width_inch – The width of the figure in inches, If set, forces fixed total size.
__init__(subplot_size_inch=2, fig_width_inch=None)[source]

If fig_width_inch set, fixed setting for fixed total figure size in inches. Otherwise use subplot_size_inch to determine default font sizes etc., and figure will then be as wide as necessary to show all subplots at specified size.

Parameters:
  • subplot_size_inch – Determines the size of subplots, and hence default font sizes
  • fig_width_inch – The width of the figure in inches, If set, forces fixed total size.

Methods

__init__([subplot_size_inch, fig_width_inch]) If fig_width_inch set, fixed setting for fixed total figure size in inches.
rcSizes([axes_fontsize, lab_fontsize, ...]) Sets the font sizes by default from matplotlib.rcParams defaults
setWithSubplotSize([size_inch, size_mm]) Sets the subplot’s size, either in inches or in millimeters.