Skip to content

Error messages trying to compute ensemble statistics #1923

Answered by aulemahal
knlowman asked this question in Questions
Discussion options

You must be logged in to vote

Hi @knlowman,

For both errors, I think one issue is that you didn't expect that ensemble_mean_std_max_min takes ONLY Datasets as input. We don't have a real reason for this, the function could easily be made to accept DataArray as well (a good first contribution maybe ;) )?

For the second error, try doing :

ensembles.ensemble_mean_std_max_min(ctrl_ens[['temp']])

Here I am using xarray's feature of selecting a list of (data) variables, which returns a Dataset with only that (data) variable. Keeping all relevant coordinates and attributes.

And the first error. dtype('<M8[ns]') means that one of the data variables in your dataset is made of datetimes. Are you expecting of taking the mean/std…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@knlowman
Comment options

Answer selected by knlowman
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
support Questions and help for users/developers
2 participants