act.plotting.DistributionDisplay

class act.plotting.DistributionDisplay(ds, subplot_shape=(1,), ds_name=None, **kwargs)[source]

This class is used to make distribution related plots. It is inherited from Display and therefore contains all of Display’s attributes and methods.

Examples

To create a DistributionDisplay with 3 rows, simply do:

ds = act.io.read_arm_netcdf(the_file)
disp = act.plotting.DistsributionDisplay(ds, subplot_shape=(3,), figsize=(15, 5))

The DistributionDisplay constructor takes in the same keyword arguments as plt.subplots. For more information on the plt.subplots keyword arguments, see the matplotlib documentation. If no subplot_shape is provided, then no figure or axis will be created until add_subplots or plots is called.

add_colorbar(mappable[, title, ...])

Adds a colorbar to the plot.

add_subplots([subplot_shape, secondary_y, ...])

Adds subplots to the Display object.

assign_to_figure_axis(fig, ax)

This assigns the Display to a specific figure and axis.

group_by(units)

Group the Display by specific units of time.

plot_heatmap(x_field, y_field[, dsname, ...])

This procedure will plot a heatmap of a histogram from 2 variables.

plot_pie_chart(fields[, time, time_slice, ...])

This procedure will produce a pie chart for the selected fields.

plot_scatter(x_field, y_field[, m_field, ...])

This procedure will produce a scatter plot from 2 variables.

plot_size_distribution(field, bins[, time, ...])

This procedure plots a stairstep plot of a size distribution.

plot_stacked_bar(field[, dsname, bins, ...])

This procedure will plot a stacked bar graph of a histogram.

plot_stairstep(field[, dsname, bins, ...])

This procedure will plot a stairstep plot of a histogram.

plot_violin(field[, positions, dsname, ...])

This procedure will produce a violin plot for the selected field (or fields).

put_display_in_subplot(display, subplot_index)

This will place a Display object into a specific subplot.

set_ratio_line([subplot_index])

Sets the 1:1 ratio line.

set_xrng(xrng[, subplot_index])

Sets the x range of the plot.

set_yrng(yrng[, subplot_index])

Sets the y range of the plot.