Helper routines for enforcing axis aspect ratios in figures
Detect whether a collection of plots contains at least one pie chart
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(plot_data_t), | intent(in) | :: | plots(:) | |||
| integer, | intent(in) | :: | plot_count |
Check if every plot in the collection is a pie chart
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(plot_data_t), | intent(in) | :: | plots(:) | |||
| integer, | intent(in) | :: | plot_count |
Adjust the figure axis limits so pie charts render with equal scaling
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(figure_state_t), | intent(inout) | :: | state | |||
| real(kind=wp), | intent(in), | optional | :: | plot_width_px | ||
| real(kind=wp), | intent(in), | optional | :: | plot_height_px |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(figure_state_t), | intent(inout) | :: | state | |||
| real(kind=wp), | intent(in) | :: | plot_width_px | |||
| real(kind=wp), | intent(in) | :: | plot_height_px |
Widen one data range about its centre so that one y data unit spans aspect_ratio times the pixel length of one x data unit ('equal': ratio 1) in a plot box of plot_width_px x plot_height_px (matplotlib's adjustable='datalim'). 'auto' leaves the limits.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| character(len=*), | intent(in) | :: | aspect_mode | |||
| real(kind=wp), | intent(in) | :: | aspect_ratio | |||
| real(kind=wp), | intent(in) | :: | plot_width_px | |||
| real(kind=wp), | intent(in) | :: | plot_height_px | |||
| real(kind=wp), | intent(inout) | :: | x_min | |||
| real(kind=wp), | intent(inout) | :: | x_max | |||
| real(kind=wp), | intent(inout) | :: | y_min | |||
| real(kind=wp), | intent(inout) | :: | y_max |