Replies: 3 comments
-
I would be happy to work on this. For my use case, my integrand comes from a selection of a range of values - I thus have a single continuous block of finite values within a large pool of NaN. We could, as a first approximation, raise an exception if the integrated data is not in a continuous block, and that would already be helpful. |
Beta Was this translation helpful? Give feedback.
-
Just wondering if we already have any advances on this... |
Beta Was this translation helpful? Give feedback.
-
Opened an issue to track this enhancement request at #7894. Anyone who wants to have a go at contributing this feature would be welcome to! |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
I am using the Dataset.integrate() function and noticed that because one of my variables has a NaN in it the function returns a NaN for the integrated value for that variable. I know based on the trapezoidal rule one could not get an integrated value at the location of the NaN, but is it not possible for it to calculate the integrated values where there were regular values?
Assuming 0 for NaNs does not work because it would still integrate between the values before and after 0 and add additional area I do not want. Using DataArray.dropna() also is not sufficient because it would assume the value before the NaN is then connected to the value after the NaN and again add additional area that I would not want included.
If a "skipna" functionality or something could not be added to the integrate function, does anyone have a suggestion for another way to get around to calculating my integrated area while excluding the NaNs?
Beta Was this translation helpful? Give feedback.
All reactions