Open mahf708 opened 1 year ago
Hi @mahf708 Thanks for the suggested change. It would be nice to have the default behavior polished so that we can rely less on manually set the fields for colorbars. I'm also curious about your solution for convert scientific notion to a unit that can be readily printed and shown as metrics. I wondered if there is a generic solution to convert large/small values, while have reasonable metrics values to be printed.
In comparison (i.e., model-vs-model or model-vs-obs) plots, the default non-specified behavior is often unsatisfactory, and the current approach in this repository is to manually set/specify "sane defaults" for each derived (or raw) variable in the ini/cfg files. See the first example below for one derived parameter I've recently aded as part of the aerosol working group efforts.
A three-panel figure without specifying the colorbars
![image](https://github.com/E3SM-Project/e3sm_diags/assets/122953255/e6b6b8d7-ff52-4e96-87eb-1a3ee9638fb9)
In order to fix the plots, I had to manually set
contour_levels
anddiff_levels
so that the colorbars are more informative. See below.A three-panel figure with specifying the colorbars
![](https://web.lcrc.anl.gov/public/e3sm/diagnostic_output/ac.ngmahfouz/E3SMv3_dev/pd.free.3b3a953.v3alpha02.plus0K.chrysalis/misc/lat_lon/lat_lon_mass_328mb/pi.free.3b3a953.v3alpha02.plus0K.chrysalis-Mass_so4_328mb-ANN-global.png)
In this particular case, I made two quick edits.
**
I think setting the default behavior to be like 2 above makes more sense than letting the plotting libraries choose (current behavior). Thankfully, we already have all the values of interest calculated (min and max) and the plotting functionality can easily accept these new defaults without disrupting the current behavior of e3sm_diags since most (if not all) variables have their defaults overridden by the manually set configs. Therefore, I propose we adopt the items in point 2 above as new defaults.
Pros:
Cons (I chose the above example on purpose to illustrate the drawbacks of this proposal ahead of time):
**
I am going to adopt the above solution in my fork for our custom diagnostics, but it may be good to adopt it for all of e3sm_diags.
Let me know if you have any feedback or thoughts on this. If there is openness to this proposal, I can draft a PR with the necessary changes to make it more actionable.