anesthetic.gui package
Graphical user interface for inspecting nested sampling runs.
anesthetic.gui.plot module
Main plotting tools.
- class anesthetic.gui.plot.Beta(beta, D_KL, fig, gridspec, action)[source]
Bases:
Slider
Slider controlling inverse temperature of the posterior points.
- class anesthetic.gui.plot.Evolution(logX, fig, gridspec, action)[source]
Bases:
Slider
Slider controlling the evolution stage of the live points.
- class anesthetic.gui.plot.Higson(fig, gridspec)[source]
Bases:
Widget
Higson plot as shown in https://arxiv.org/abs/1703.09701 .
- Attributes:
- curve
matplotlib.lines.Line2D
points currently plotted as a curve.
- point
matplotlib.lines.Line2D
large indicator point currently plotted on the curve.
- curve
- class anesthetic.gui.plot.RunPlotter(samples, params=None)[source]
Bases:
object
Construct a control panel of information on a nested sampling run.
- Parameters:
- samples
anesthetic.samples.NestedSamples
The root string for the chains files to be used, or a set of nested samples.
- samples
- Attributes:
- samples
anesthetic.samples.NestedSamples
Object for extracting nested sampling data from chains files.
- fig
matplotlib.figure.Figure
Reference to the underlying figure
- triangle
anesthetic.gui.widgets.TrianglePlot
Corner plot of live or posterior samples.
- beta
anesthetic.gui.plot.Beta
Slider selecting the posterior inverse temperature.
- evolution
anesthetic.gui.plot.Evolution
Slider selecting the live iteration.
- higson
anesthetic.gui.plot.Higson
Higson plot of posterior weights.
- reset
anesthetic.gui.widgets.Button
Button that resets the parameter ranges.
- reload
anesthetic.gui.widgets.Button
Button that reloads the files.
- type
anesthetic.gui.widgets.RadioButtons
Radio buttons that selects whether to plot live or posteriors.
- param_choice
anesthetic.gui.widgets.CheckButtons
Checkbox that selects which parameters to plot.
- samples
anesthetic.gui.widgets module
Widget wrappers to matplotlib.
These extend the matplotlib widgets by plotting themselves onto an axis and storing a reference to both the widget object and the axis on which they are plotted.
- class anesthetic.gui.widgets.Button(fig, gridspec, action, text)[source]
Bases:
Widget
Push button that performs an action.
- Parameters:
- action: func
What should be run upon clicking the button.
- text: str
Overlay text on the button.
- Attributes:
- button: :class:`matplotlib.widgets.Button`
matplotlib Button.
- class anesthetic.gui.widgets.CheckButtons(fig, gridspec, labels, action)[source]
Bases:
LabelsWidget
Set of checkboxes.
Defaults to choosing the only the first label at start.
- Parameters:
- action: func
What should be done upon checking the box.
- Attributes:
- buttons: :class:`matplotlib.widgets.CheckButtons`
matplotlib CheckButtons.
- class anesthetic.gui.widgets.LabelsWidget(fig, gridspec, labels)[source]
Bases:
Widget
Widget with labels to choose from.
- Parameters:
- labels: list(str)
Set of labels to be tied to Widget.
- Attributes:
- labels: list(str)
Set of labels on Widget.
- class anesthetic.gui.widgets.RadioButtons(fig, gridspec, labels, action)[source]
Bases:
LabelsWidget
Set of radio selection choices.
- Parameters:
- labels: list(str))
- Attributes:
- buttons: :class:`matplotlib.widgets.RadioButtons`
matplotlib RadioButtons.
- class anesthetic.gui.widgets.Slider(fig, gridspec, action, text, valmin, valmax, valinit, orientation)[source]
Bases:
Widget
Choose a parameter via a slider widget.
- Parameters:
- action: func
What should be done upon altering the slider.
- text: str
Text at the start of the slider.
- valmin, valmax, valinit: float
Range and initial value for the slider.
- orientation: str
Orientation for slider (‘horizontal’ or ‘vertical’).
- Attributes:
- slider: :class:`matplotlib.widgets.Slider`
matplotlib Slider.
- class anesthetic.gui.widgets.TrianglePlot(fig, gridspec)[source]
Bases:
Widget
Triangle plot widget as exemplified by getdist and corner.py.
For other examples of these plots, see: https://getdist.readthedocs.io https://corner.readthedocs.io
- Attributes:
- ax: :class:`pandas.DataFrame`(:class:`matplotlib.axes.Axes`)
Mapping from pairs of parameters to axes for plotting.
- class anesthetic.gui.widgets.Widget(fig, gridspec)[source]
Bases:
object
Base class for anesthetic gui widgets.
Stores a reference to the underlying figure, the gridspec that the widget is placed at and the axes of the widget.
- Parameters:
- fig: :class:`matplotlib.figure.Figure`
Figure for drawing widget on.
- gridspec: matplotlib.gridspec.GridSpec
Specification for where to draw in the figure. Technically could be any argument that can be passed to
matplotlib.figure.Figure.add_subplot()
.
- Attributes:
- fig: :class:`matplotlib.figure.Figure`
Figure for drawing widget on.
- gridspec: matplotlib.gridspec.GridSpec
Specification for where to draw in the figure. Technically could be any argument that can be passed to
matplotlib.figure.Figure.add_subplot()
.- ax: :class:`matplotlib.axes.Axes`
Axes of widget.