censor_thresh in plot_data_plane and grid_stat #2892
-
Hi, My question is almost identical to discussion item#1389 [https://github.com//discussions/1389]. I have a grid I'm reading into MET with python embedding. It reads into grid_stat and plot_data_plane without issue. However, I would like to use the censor_thresh option in grid_stat. When I set the option, I do not receive an error, but the stat results indicate that my censor_thresh setting was ignored by grid_stat. This works without issue: This does not work, only difference is that the censor_thresh option is added *** Model Evaluation Tools (METV12.0.0) *** Usage: plot_data_plane Thanks, |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments 4 replies
-
Hi Matt: I see two things in the second command above that may be causing the issue. The first is that although censor_thresh is added in the second command, censor_val is not part of that command. For censor_thresh to work, you need both the censor_thresh and censor_val set. The censor_thresh provides a threshold for data that you want to censor, while censor_val is the value that these values should be changed to. Since no censor_val was provided, the censor_thresh option should produce no change. The second is that the censor_thresh and censor_val need to be inside the single quote with the name variable for the Plot-Data-Plane command. If you want to set your missing data to 0, as is done in discussion 1389, then I think you need the following command to do that:
If you run the command as above, does this produce the desired result on your end? Thanks, |
Beta Was this translation helpful? Give feedback.
-
Thank you, Christina. Using your two suggestions and the command provided, I was able to get plot_data_plane to work. Grid_stat also worked, and I can see that censor points are being excluded in the stat calculations. Ultimately, I would like to use the censor_thresh and val method with grid_stat to restrict points entering the stats calculation. Using this approach instead of a binary mask (applied based on the same criteria) yields slightly different results in the number of points retained in the stats calculation. I'm not exactly sure why a difference exists. I must be missing some little nuance. Thanks again. Matt |
Beta Was this translation helpful? Give feedback.
-
Hi Christina, I am using a binary mask 0/1 and there is no regridding (same grid) being performed. I also did test using a censor_thresh as you suggested "censor_thresh = lt-9000", but the same differences remained. I'll keep tinkering with it. I'm probably missing a small item. Thanks again for all the help. |
Beta Was this translation helpful? Give feedback.
-
Hi Christina, |
Beta Was this translation helpful? Give feedback.
Hi Matt:
I see two things in the second command above that may be causing the issue. The first is that although censor_thresh is added in the second command, censor_val is not part of that command. For censor_thresh to work, you need both the censor_thresh and censor_val set. The censor_thresh provides a threshold for data that you want to censor, while censor_val is the value that these values should be changed to. Since no censor_val was provided, the censor_thresh option should produce no change.
The second is that the censor_thresh and censor_val need to be inside the single quote with the name variable for the Plot-Data-Plane command.
If you want to set your missing data to 0, as is …