Skip to content

GridStat trouble reading probabilistic grib field #2107

Locked Answered by CPKalb
lindsayrblank asked this question in File I/O
Discussion options

You must be logged in to vote

Hi Lindsay:

Getting the format right for probabilities can be tough. The True/False is for netCDF files, whereas grib/grib2 files need a dictionary specified in the prob variable. I'm guessing you need to change the format of your input data to look something like:

fcst = {

  cat_thresh = [ ==0.1 ];

 field = [{
     name = "PROB";
     level = "Z2";
     prob = { name = "TMP"; thresh_lo = 258.15; thresh_hi = 268.15;} }
 ];

}

*I'm not sure if I set the thresh_hi and thresh_lo you are wanting to use as I just picked one that was in the file. But, the above values pull record number 21. If I instead set prob = { name = "TMP"; thresh_hi = 258.15;}, it will pull record number 28.

I was able …

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@lindsayrblank
Comment options

@CPKalb
Comment options

Answer selected by lindsayrblank
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment