geoschem / gcpy

Python toolkit for GEOS-Chem. Contains basic plotting scripts, plus the suite of GEOS-Chem benchmarking utilities.
https://gcpy.readthedocs.io
Other
50 stars 24 forks source link

[BUG/ISSUE] Zonal mean plots with pressure subset are incorrect when y-axis flipped #45

Closed lizziel closed 4 years ago

lizziel commented 4 years ago

Using the pressure subsetting option in compare_zonal_mean works correctly when the flip_ref and/or flip_dev are set to the default value (False). However, it seems that the plots are not correct if the vertical axis is flipped.

For example, here are concentration plots for Br2 mean full column (no subsetting) with the vertical axis of the Dev data flipped. This is comparing a GCC restart file with a GCHP restart file, so this flipping is necessary.

Br2_rst_zonal_log_partial

To hone in on the stratosphere I use the pressure subsetting for interval [1,100]. This is what is plotted:

Br2_rst_zonalstrat_log_partial

I suspect the issue is the order of the subsetting and the flipping. I will investigate.

yantosca commented 4 years ago

I wonder if the 0, 0 is because it is printing integers on the axis. Maybe it should go like 1, 0.2, 0 or something like that. You could tweak with the formatter and specify a single decimal space.

lizziel commented 4 years ago

See https://github.com/geoschem/gcpy/issues/44 for discussion of the 0, 0.

The pressure subset issue when y-axis flipped is fixed with https://github.com/geoschem/gcpy/commit/e808366a310e8b87950605a97a24a606321516dd.

Screen Shot 2019-11-04 at 4 36 54 PM