Skip to content

Conversation

lassejsc
Copy link
Contributor

@lassejsc lassejsc commented Oct 8, 2025

Added option for horizontal colorbar for all the plot functions with cbaxes kword, changes based on #237.
Currently changed:

  • plot_vdf
  • plot_colormap
  • plot_colormap3d(cherry picked from Horizontal colorbar support #237 for one of the scripts in scripts folder and added to the main package also)
  • plot_neutral_sheet
  • plot_ionosphere

Also adds colorbar calls to testpackage.

Example plot_vdf when cbaxes and axes are passed to it

test_vdf_hor

Also added semi sensible default placements for horizontal colorbar if only cb_horizontal=True is passed to these. Note that for vdf and vdfdiff this may not always look good as I believe the figure size comes from the data.

vdf:
plot_vdf

vdfdiff:
plotvdfdiff

Here I reduced the number of ticks when plotting with horizontal bar, because matplotlib is giga annoying to work with and I could not easily a) make the ticks have decimal precision of just 1 b) widen the colorbar. This may only be an issue if the main plot is too narrow and it depends on the data I presume.

colormap:
colormap

colormap3dslice:
3dslice

plot_neutral_sheet:
plot_neutral_sheet_horizontalcb

ionosphere:
vdftestplot2iono
Note that this is after the change in #363 , which is not included in this PR

@lassejsc lassejsc closed this Oct 8, 2025
@lassejsc lassejsc deleted the horizontal_colorbar branch October 8, 2025 13:07
@lassejsc lassejsc restored the horizontal_colorbar branch October 8, 2025 13:26
@lassejsc lassejsc reopened this Oct 8, 2025
@lassejsc lassejsc changed the title Horizontal colorbar support for all relevant plot functions Horizontal colorbar support for all relevant plot functions with colorbar Oct 9, 2025
@lassejsc lassejsc marked this pull request as ready for review October 9, 2025 07:46
@alhom
Copy link
Member

alhom commented Oct 10, 2025

Please add example figure outputs for reference.

@alhom
Copy link
Member

alhom commented Oct 10, 2025

And please add testpackage lines where available (plot_colormap, _vdf)

@lassejsc lassejsc marked this pull request as draft October 10, 2025 11:59
@lassejsc lassejsc marked this pull request as ready for review October 10, 2025 12:24
@alhom
Copy link
Member

alhom commented Oct 13, 2025

Very good! Two more things:

  1. For reference and for exercise, also please add example outputs for the other plot types you have modified.
  2. Please revert plot_colormap3dslice.py to master and cherry-pick the original edit in its place to conserve author/blame history.

lassejsc and others added 3 commits October 13, 2025 13:00
… given `axes`, lastly hid the axis on the given `axes` such that it doesnt show on the plot by default.
@lassejsc lassejsc marked this pull request as draft October 14, 2025 06:32
@lassejsc lassejsc marked this pull request as ready for review October 16, 2025 10:16
@lassejsc lassejsc marked this pull request as draft October 16, 2025 10:16
@lassejsc lassejsc marked this pull request as ready for review October 16, 2025 10:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants