read_wrf_nc - Options


Options:      (Note: options [-att] ; [-t] and [-diag] can be used with other options)

-h / help

Prints help information.

-att

Prints global attributes.

-m

Prints list of fields available for each time, plus the min and max values for each field.

-M z

Prints list of fields available for each time, plus the min and max values for each field.
The min and max values of 3d fields will be for the z level of the field.

-s

Prints list of fields available for each time, plus a sample value for each field.
Sample value is taken from the middle of the model domain.

-S x y z

Prints list of fields available for each time, plus a sample value for each field.
Sample value is at point x, y, z in the model domain.

-t t1 [t2]

Applies options only to times t1 to t2.
t2 is optional. If not set, options will only apply to t1.

-times

Prints only the times in the file.

-ts

Generates time series output. A full vertical profile for each variable will be created.
-ts xy X  Y  VAR VAR …..
will generate time series output for all VAR’s at location X/Y
-ts ll lat lon VAR VAR …..
will generate time series output for all VAR’s at x/y location nearest to lat/lon

-lev z

Works only with option –ts
Will only create a time series for level z

-rot

Works only with option –ts
Will rotate winds to Earth coordinates

-diag

Add if you want to see output for the diagnostics temperature (K), full model pressure and model height (tk, pressure, height)

-v VAR

Prints basic information about the field VAR.

-V VAR

Prints basic information about the field VAR, and dumps the full field out to the screen.

-w VAR

Writes the full field out to a file VAR.out

 

 

 

Default Options are [-att –s]


SPECIAL option : -EditData VAR

This option allows a user to read a WRF netCDF file, change a specific field, and write it BACK into the WRF netCDF file.
This option will CHANGE your CURRENT WRF netCDF file, so TAKE CARE when using this option.
ONLY one field at a time can be changed. So if you need 3 fields changed, you will need to run this program 3 times, each with a different "VAR"
IF you have multiple times in your WRF netCDF file – by default ALL times for variable "VAR" WILL be changed. If you only want to change one time period, also use the “-t” option.
 

HOW TO USE THIS OPTION:

**Make a COPY of your WRF netCDF file before using this option**

EDIT the subroutine USER_CODE

ADD an IF-statement block for the variable you want to change. This is to prevent a variable getting overwritten by mistake.

For REAL data arrays, work with array "data_real" and for INTEGER data arrays, work with the array "data_int".

Example 1:
If you want to change all values of U (for all time periods) to a constant 10.0 m/s, you would add the following IF-statement:
   elseif ( var == 'U') then
     data_real = 10.0

Example 2:
If you want to change a section of the LANDMASK data to SEA points:
   elseif ( var == 'LANDMASK') then
     data_real(10:15,20:25,1) = 0

Example 3:
Change all ISLTYP category 3 values into category 7 values (NOTE this is an INTEGER field):
   elseif ( var == 'ISLTYP') then
     where (data_int == 3 )
       data_int = 7
     endwhere

Compile and run the program
You will be asked if this is really what you want to do.
ONLY the answer "yes" will allow the change to take effect