PCP-Combine

PCP-Combine cindyhg Wed, 04/24/2019 - 12:19

Functionality

The PCP-Combine tool is used (if needed) to sum, add, or subtract accumulated precipitation from one or more gridded data files into a single NetCDF file containing the desired accumulation period. Its NetCDF output may be used as input to the MET statistics tools. It may be run to sum the same accumulation interval across multiple files, to add data from one or more files, or to subtract data from exactly two files. The sumadd, and subtract options may be run on any gridded data file supported by MET. The input files being combined must have already been placed on the grid on which the user would like to verify. The copygb and wgrib2 utilities are recommended for re-gridding GRIB1 and GRIB2 files, respectively. In addition, the PCP-Combine tool will only sum model files with the same initialization time unless it is told to ignore the initialization time.

PCP-Combine Usage

View the usage statement for PCP-Combine by simply typing the following:

pcp_combine

Use the -sum-add, -subtract, or -derive command line option to indicate the operation to be performed. Each operation has its own set of required arguments.

By default, PCP-Combine searches for records containing GRIB code 61 (accumulated precipitation). Use the -config config_str option to override this default and process other fields.

Run

Run cindyhg Wed, 04/24/2019 - 12:22

Since PCP-Combine performs a simple operation and reformatting step, no configuration file is needed.

Run PCP-Combine on the command line using the following two commands:

pcp_combine \
-sum 20050807_000000 3 20050808_000000 12 \
$MET_TUTORIAL_DATA/output/pcp_combine/sample_fcst_24L_2005080800V_12A.nc \
-pcpdir $MET_TUTORIAL_DATA/input/sample_fcst/2005080700

pcp_combine \
-sum 00000000_000000 1 20050808_000000 12 \
$MET_TUTORIAL_DATA/output/pcp_combine/sample_obs_2005080800V_12A.nc \
-pcpdir $MET_TUTORIAL_DATA/input/sample_obs/ST2ml

In the first command, PCP-Combine summed up 4 3-hourly accumulation forecast files into a single 12-hour accumulation forecast. In the second command, PCP-Combine summed up 12 1-hourly accumulation observation files into a single 12-hour accumulation observation. PCP-Combine should perform these tasks very quickly. In the second command, we told PCP-Combine to ignore the initialization time by setting its YYYYMMDD_HHMMSS to all zeros (0000000_000000).

Output

Output cindyhg Wed, 04/24/2019 - 12:22

When PCP-Combine is finished, you may view the output NetCDF files it wrote using the ncdump and ncview utilities (if available on your machine). Run the following commands to view contents of the NetCDF files:

ncview $MET_TUTORIAL_DATA/output/pcp_combine/sample_fcst_24L_2005080800V_12A.nc &
ncview $MET_TUTORIAL_DATA/output/pcp_combine/sample_obs_2005080800V_12A.nc &

ncdump -h $MET_TUTORIAL_DATA/output/pcp_combine/sample_fcst_24L_2005080800V_12A.nc
ncdump -h $MET_TUTORIAL_DATA/output/pcp_combine/sample_obs_2005080800V_12A.nc

The ncview windows display plots of the precipitation data in these files. The output of ncdump indicates that the gridded fields are named APCP_12, the GRIB code abbreviation and accumulation interval for precipitation. We'll use these NetCDF output files from PCP-Combine as input for the Grid-Stat tool.