das-developers / das2java

The original das2 library. Provides interactive publication-ready 2-D plotting
https://das2.org
GNU Lesser General Public License v3.0
4 stars 0 forks source link

QDataSet.CADENCE_MIN and QDataSet.CADENCE_MAX introduction #41

Open jbfaden opened 2 years ago

jbfaden commented 2 years ago

I've been thinking about adding QDataSet.CADENCE_MIN and QDataSet.CADENCE_MAX, which would be alternatives to QDataSet.CADENCE. This would fix a problem were sometimes you want to know an upper or a lower limit, and this would allow codes and datasets to support this. I've always imagined that QDataSet.CADENCE might be allowed to be a rank 1 dataset, and this might be a better solution here as well.

As with any QDataSet property, any property can be missing, and the three must be considered as group now, CADENCE_MIN=CADENCE_MAX -> CADENCE=CADENCE_MIN, etc.

jbfaden commented 1 year ago

CADENCE_MAX would be used for interpolation, CADENCE_MIN would be used for extrapolation.

jbfaden commented 1 year ago

Note some care is needed with CADENCE_MAX or CADENCE_MIN being missing while CADENCE is present. If CADENCE_MAX is missing, does it mean that CADENCE should be used, or that there's no apparent CADENCE_MAX? How about with CADENCE_MIN?

jbfaden commented 11 months ago

I was just running into an issue with one of the guessCadence codes, this one where I try to use GCD of the diffs: DataSetUtil.guessCadence. There really needs to be a solid definition of cadence and a solid routine to identify it.