OpenCDSS / cdss-lib-common-java

Colorado's Decision Support Systems (CDSS) common library (Java)
GNU General Public License v3.0
0 stars 1 forks source link

Add box plot #186

Open smalers opened 1 year ago

smalers commented 1 year ago

It would be good to have a box plot (box and whiskers) as one of the default plot types, for use in TSTool. Technical considerations include:

  1. Layout on the graph would be similar to bar graphs.
  2. Consequently, need to be aware of the time-axis placement of the box, perhaps automatically create regular interval time series as having the right edge at the end of the interval.
  3. Would need to default the configuration properties but seems to be pretty standard (media, quartiles, min and max values).
  4. Need to add to the time series properties editor and product file.
  5. The box plot requires, for each time interval:
    1. Median value for sample in the interval.
    2. Quartile values on each side of the median.
    3. Maximum.
    4. Minimum.
  6. The time series representation could be:
    1. If the output interval is year, each year's sample would be the values in the year, similar to NewStatisticYearTS command.
    2. If the output interval is month, the output could be 12 values where all January values are in the sample, or the output could be the full period where each month's sample values are for that month.
    3. Similar for day, hour, and minute interval (not sure whether small intervals make sense but could be useful to show the temporal distribution within a day).
  7. One challenge is how to store the additional values at a date/time:
    1. Parallel time series, such as an ensemble that has original data and statistic time series (problem is they will have different intervals)? Could track as time series property that is a full separate time series (not a simple string property). Maybe add a "related time series" list to each time series, which as other applications.
    2. Compute as needed in the graphing code? This might be necessary for a default view, but the user would need to be able to configure. Even if computed internally, would benefit from the design from the above.