dtcenter / METcalcpy

https://metcalcpy.readthedocs.io/en/latest/index.html
Apache License 2.0
16 stars 2 forks source link

Enhance METcalcpy to aggregate statistics added to the ECNT, VL1L2, VAL1L2, and VCNT line types during the MET 12.0.0 beta4 development cycle #361

Closed JohnHalleyGotway closed 5 months ago

JohnHalleyGotway commented 7 months ago

Describe the Enhancement

Issue dtcenter/METdataio#282 updates the schema to load new wind direction statistics from the VL1L2, VAL1L2, and VCNT line types of MET version 12.0.0 and new ignorance score statistics to the ECNT line type. This issue is to update METcalcpy to update the aggregation logic for the VL1L2, VAL1L2, VCNT, and ECNT line types to handle these new columns of data. Please see @JohnHalleyGotway with any questions you may have about the aggregation logic.

Time Estimate

Estimate the amount of work required here. Issues should represent approximately 1 to 3 days of work.

Sub-Issues

Consider breaking the enhancement down into sub-issues.

Relevant Deadlines

List relevant project deadlines here or state NONE.

Funding Source

Define the source of funding and account keys here or state NONE.

Define the Metadata

Assignee

Labels

Projects and Milestone

Define Related Issue(s)

Consider the impact to the other METplus components.

Enhancement Checklist

See the METplus Workflow for details.

JohnHalleyGotway commented 5 months ago
  1. For the VL1L2 columns:

    • DIR_ME, DIR_MAE, DIR_MSE: Aggregate these simply as a weighted average of the input statistics, where the weight is defined by the TOTAL column.
      'vl1l2_dir_me': ['dir_me'],
      'vl1l2_dir_mae': ['dir_mae'],
      'vl1l2_dir_mse': ['dir_mse'],
  2. For the VCNT columns:

    • DIR_ME, DIR_MAE, DIR_MSE: Aggregate these simply as a weighted average of the input statistics, where the weight is defined by the TOTAL column.
      'vcnt_dir_me': ['dir_me'],
      'vcnt_dir_mae': ['dir_mae'],
      'vcnt_dir_mse': ['dir_mse'],
    • DIR_RMSE: Aggregate DIR_MSE, as described above, and then take the square root.
      'vcnt_dir_rmse': ['dir_mse'],
  3. For the VAL1L2 columns:

    • DIRA_ME, DIRA_MAE, DIRA_MSE: Aggregate these simply as a weighted average of the input statistics, where the weight is defined by the TOTAL column.
      'val1l2_dira_me': ['dira_me],
      'val1l2_dira_mae': ['dira_mae],
      'val1l2_dira_mse': ['dira_mse],
  4. For the ECNT columns:

    • IGN_CONV_OERR, IGN_CORR_OERR: Aggregate these simply as a weighted average of the input statistics, where the weight is defined by the TOTAL column.

In general, when adding aggregation logic to METcaclpy, recommend testing and validating using MET's Stat-Analysis tool to make sure we get consistent results. e.g. run the -job aggregate and/or -job aggregate_stat job types.