-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
added units flag scatter #134
Conversation
Great initiative. But I think it's quite important that we ensure consistent units across all plot types. I don't think the units should be passed as an argument to each plot but rather set someplace central. |
As of now the units are extracted from I understand what you mean of the central place, but this skill table I only implemented for the scatter plot and not for the timeseries or spatial skill (at least not yet). We already merged the table (without units) to the main branch, so at least I think that we should either step back from the last merge and remove the skill table, or, leave it as it is of now and then maybe think in another centralized way. |
@ecomodeller pls don't forget this branch when you have some time! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alright, I agree, let me try to think this through, in a central place we could also call the units for spatial_skill plots. |
@ecomodeller I fully re-made how the units and skill table work.
Default plots (no units overwriting, read from file)Plots overwriting unitsSame but for satellites, without and with units replacement same with units replacement, just 1 plot to exemplify I think this is what everyone wanted |
@ecomodeller I cannot |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think I addressed all these comments
e229bea
to
f08baea
Compare
I am writing the tests now but I can see that despite my |
253503c
to
7ad1cc7
Compare
@ecomodeller I added a series of tests regarding the new functionality, also that made me modify the plotting a little bit to avoid some errors, and Jesper suggested to Temporarily remove python 3.7 tests as they are all failing due to some xarray update, we can add them later. |
Or maybe stop supporting Python 3.7 !? - see this discussion in xarray: pydata/xarray#6138 |
Added an automatic units recognition from dfs0.item for singlepoint compare object scatter plot.
units=str
can be specified, for instance if instead of automatic units detectionunits = °
user wanted to specify degrees north then flagunits = ' °N'
can be specified.units = 'cm/s'
. This could be improved in the future with a very long mapping dictionary oflong unit name -> short unit name
.now looks like this with units on the side (no extra kword, units extracted automatically from dfs0)
track-comparer object
scatter plot (should be copy-pasting of the code)