- liesel.goose.summary_viz.plot_param(results, param, param_index=None, chain_indices=None, max_chains=5, max_lags=None, title=None, title_spacing=0.9, style='whitegrid', color_list=None, figure_size=(9, 6), legend_position=(1.2, 0.4), save_path=None)#
Visualizes trace plot, density plot and autocorrelation plot of a single subparameter.
SamplingResults) – Result object of the sampling process. Must have a method
get_posterior_samples()which extracts all samples from the posterior distribution.
str) – Name of a single model parameter that is contained in the plot. Must coincide with one dictionary key of the
Positionwith the posterior samples.
int]) – A single index of the selected model parameter that is contained in the plot. (default:
None) Selects e.g.
betaout of a
betaparameter vector. Can be specified as an integer or as a sequence containing one integer. If
None, the parameter is assumed to have only a single index.
None]) – Indices of chains for each model subparameter that are contained in the plot. (default:
None) Selects e.g. chain 0 and chain 2 out of multiple chains. A single index can be specified as an integer or a sequence containing one integer. If
None, all chains are included.
int]) – Upper bound how many chains are included within each subplot/facet. Avoids (default:
5) overplotting. If
None, all chains contained in the
resultsinput are plotted. Always starts chain selection from the lowest chain index upwards. For selecting specific chains use the argument
float) – Determines the margin/whitespace between the plot title (set with (default:
fig.suptitle()) and the first row of subplots/facets. Passed to the
str) – Passed to the
sns.set_theme(). Valid options are (default:
str]]) – Determines the chain colors for all three subplots. Custom colors can be passed (default:
None) with a list of color strings. The length of the list must match the number of chains. If
None, the default
tab10matplotlib colormap is chosen.
float]) – Size of the entire plot grid. Passed to the
figsizeargument of (default:
plt.figure(). When changing the figure size consider changing the
legend_positionas well. Generally, a ratio of 3
float]) – Determines the color legend position. Coordinates are relative to the upper (default:
(1.2, 0.4)) panel within the plot grid. The first coordinate specifies the horizontal, the second coordinate the vertical position. Might require an adjustment when changing the
figure_sizevalues or the number of chains.
- Return type: