Radar Resources / Radar Data / Data Inventory

Radar Decoding - Easy Solution!


This example converts NEXRAD data into the NetCDF format, which is readable by many software packages on virtually all platforms. No programming is needed!

Note: the NetCDF output convention will be CF-Radial. Although the data values will be accessible by NetCDF libraries, the data probably won't display on a map because most software packages only support the common CF-Gridded convention.

The 'toolsUI.jar' file has everything you need bundled into a single file and also provides a NetCDF debugger. This example is using the version 4.0 library, although I think 2.2.22 also has super-res support.

2) Run this command from your command prompt (unix or dos) ...
java -classpath toolsUI-4.0.jar ucar.nc2.FileWriter -in $in -out $out
... substituting $in and $out with your desired input filename and output filename. Example: "java -classpath toolsUI-4.0.jar ucar.nc2.FileWriter -in work/KGSP20070501_031016 -out work/KGSP20070501_031016.nc"

3) Now you have a CF-compliant NetCDF-3 file!
This file can be read with any NetCDF library in any language. Looking at the metadata (with 'ncdump' or by typing 'java -jar toolsUI-4.0.jar' and selecting NCDump), you will see variables for Reflectivity, Velocity, Spectrum Width and the additional super-res variables if present.



Below is the output of an 'ncdump' for sample Super-Res and Legacy NEXRAD files:

Super-Resolution Example:

netcdf /home/sansari/stage4/java/KPAH20080330_131826_V03 {
 dimensions:
   scanR_HI = 4;
   gateR_HI = 1832;
   radialR_HI = 720;
   scanR = 12;
   gateR = 458;
   radialR = 360;
   scanV_HI = 2;
   gateV_HI = 1192;
   radialV_HI = 720;
   scanV = 12;
   gateV = 912;
   radialV = 360;
 variables:
   byte Reflectivity_HI(scanR_HI=4, radialR_HI=720, gateR_HI=1832);
     :units = "dBZ";
     :long_name = "Reflectivity_HI";
     :missing_value = 1b, 0b; // byte
     :signal_below_threshold = 0b; // byte
     :scale_factor = 0.5f; // float
     :add_offset = -33.0f; // float
     :_unsigned = "true";
     :SNR_threshold = 16s; // short
     :range_folding_threshold = 50s; // short
     :_CoordinateAxes = "timeR_HI elevationR_HI azimuthR_HI distanceR_HI";
   int timeR_HI(scanR_HI=4, radialR_HI=720);
     :long_name = "time since base date";
     :units = "msecs since 2008-03-30T13:18:26Z";
     :missing_value = -9999; // int
     :_CoordinateAxisType = "Time";
   float elevationR_HI(scanR_HI=4, radialR_HI=720);
     :units = "degrees";
     :long_name = "elevation angle in degres: 0 = parallel to 
         pedestal base, 90 = perpendicular";
     :missing_value = NaNf; // float
     :_CoordinateAxisType = "RadialElevation";
   float azimuthR_HI(scanR_HI=4, radialR_HI=720);
     :units = "degrees";
     :long_name = "azimuth angle in degrees: 0 = true north, 90 = east";
     :missing_value = NaNf; // float
     :_CoordinateAxisType = "RadialAzimuth";
   float distanceR_HI(gateR_HI=1832);
     :units = "m";
     :long_name = "radial distance to start of gate";
     :_CoordinateAxisType = "RadialDistance";
   int numRadialsR_HI(scanR_HI=4);
     :long_name = "number of valid radials in this scan";
   int numGatesR_HI(scanR_HI=4);
     :long_name = "number of valid gates in this scan";
   byte Reflectivity(scanR=12, radialR=360, gateR=458);
     :units = "dBZ";
     :long_name = "Reflectivity";
     :missing_value = 1b, 0b; // byte
     :signal_below_threshold = 0b; // byte
     :scale_factor = 0.5f; // float
     :add_offset = -33.0f; // float
     :_unsigned = "true";
     :range_folding_threshold = 50s; // short
     :_CoordinateAxes = "timeR elevationR azimuthR distanceR";
   int timeR(scanR=12, radialR=360);
     :long_name = "time since base date";
     :units = "msecs since 2008-03-30T13:18:26Z";
     :missing_value = -9999; // int
     :_CoordinateAxisType = "Time";
   float elevationR(scanR=12, radialR=360);
     :units = "degrees";
     :long_name = "elevation angle in degres: 0 = parallel to 
         pedestal base, 90 = perpendicular";
     :missing_value = NaNf; // float
     :_CoordinateAxisType = "RadialElevation";
   float azimuthR(scanR=12, radialR=360);
     :units = "degrees";
     :long_name = "azimuth angle in degrees: 0 = true north, 90 = east";
     :missing_value = NaNf; // float
     :_CoordinateAxisType = "RadialAzimuth";
   float distanceR(gateR=458);
     :units = "m";
     :long_name = "radial distance to start of gate";
     :_CoordinateAxisType = "RadialDistance";
   int numRadialsR(scanR=12);
     :long_name = "number of valid radials in this scan";
   int numGatesR(scanR=12);
     :long_name = "number of valid gates in this scan";
   byte RadialVelocity_HI(scanV_HI=2, radialV_HI=720, gateV_HI=1192);
     :units = "m/s";
     :long_name = "Radial Velocity_HI";
     :missing_value = 1b, 0b; // byte
     :signal_below_threshold = 0b; // byte
     :scale_factor = 0.5f; // float
     :add_offset = -64.5f; // float
     :_unsigned = "true";
     :SNR_threshold = 28s; // short
     :range_folding_threshold = 50s; // short
     :_CoordinateAxes = "timeV_HI elevationV_HI azimuthV_HI distanceV_HI";
   int timeV_HI(scanV_HI=2, radialV_HI=720);
     :long_name = "time since base date";
     :units = "msecs since 2008-03-30T13:18:26Z";
     :missing_value = -9999; // int
     :_CoordinateAxisType = "Time";
   float elevationV_HI(scanV_HI=2, radialV_HI=720);
     :units = "degrees";
     :long_name = "elevation angle in degres: 0 = parallel to pedestal 
         base, 90 = perpendicular";
     :missing_value = NaNf; // float
     :_CoordinateAxisType = "RadialElevation";
   float azimuthV_HI(scanV_HI=2, radialV_HI=720);
     :units = "degrees";
     :long_name = "azimuth angle in degrees: 0 = true north, 90 = east";
     :missing_value = NaNf; // float
     :_CoordinateAxisType = "RadialAzimuth";
   float distanceV_HI(gateV_HI=1192);
     :units = "m";
     :long_name = "radial distance to start of gate";
     :_CoordinateAxisType = "RadialDistance";
   int numRadialsV_HI(scanV_HI=2);
     :long_name = "number of valid radials in this scan";
   int numGatesV_HI(scanV_HI=2);
     :long_name = "number of valid gates in this scan";
   byte RadialVelocity(scanV=12, radialV=360, gateV=912);
     :units = "m/s";
     :long_name = "Radial Velocity";
     :missing_value = 1b, 0b; // byte
     :signal_below_threshold = 0b; // byte
     :scale_factor = 0.5f; // float
     :add_offset = -64.5f; // float
     :_unsigned = "true";
     :range_folding_threshold = 50s; // short
     :_CoordinateAxes = "timeV elevationV azimuthV distanceV";
   int timeV(scanV=12, radialV=360);
     :long_name = "time since base date";
     :units = "msecs since 2008-03-30T13:18:26Z";
     :missing_value = -9999; // int
     :_CoordinateAxisType = "Time";
   float elevationV(scanV=12, radialV=360);
     :units = "degrees";
     :long_name = "elevation angle in degres: 0 = parallel to 
         pedestal base, 90 = perpendicular";
     :missing_value = NaNf; // float
     :_CoordinateAxisType = "RadialElevation";
   float azimuthV(scanV=12, radialV=360);
     :units = "degrees";
     :long_name = "azimuth angle in degrees: 0 = true north, 
         90 = east";
     :missing_value = NaNf; // float
     :_CoordinateAxisType = "RadialAzimuth";
   float distanceV(gateV=912);
     :units = "m";
     :long_name = "radial distance to start of gate";
     :_CoordinateAxisType = "RadialDistance";
   int numRadialsV(scanV=12);
     :long_name = "number of valid radials in this scan";
   int numGatesV(scanV=12);
     :long_name = "number of valid gates in this scan";
   byte SpectrumWidth_HI(scanV_HI=2, radialV_HI=720, gateV_HI=1192);
     :units = "m/s";
     :long_name = "Radial Spectrum_HI";
     :missing_value = 1b, 0b; // byte
     :signal_below_threshold = 0b; // byte
     :scale_factor = 0.5f; // float
     :add_offset = -64.5f; // float
     :_unsigned = "true";
     :SNR_threshold = 28s; // short
     :range_folding_threshold = 50s; // short
     :_CoordinateAxes = "timeV_HI elevationV_HI azimuthV_HI distanceV_HI";
   byte SpectrumWidth(scanV=12, radialV=360, gateV=912);
     :units = "m/s";
     :long_name = "Radial Spectrum";
     :missing_value = 1b, 0b; // byte
     :signal_below_threshold = 0b; // byte
     :scale_factor = 0.5f; // float
     :add_offset = -64.5f; // float
     :_unsigned = "true";
     :range_folding_threshold = 0s; // short
     :_CoordinateAxes = "timeV elevationV azimuthV distanceV";

 :Station = "KPAH";
 :StationName = "Paducah,KY,US";
 :StationLatitude = 37.068333333333335; // double
 :StationLongitude = -88.77194444444444; // double
 :StationElevationInMeters = 119.0; // double
 :geospatial_lat_min = 34.998843873694064; // double
 :geospatial_lat_max = 39.13782279297261; // double
 :geospatial_lon_min = -91.3655587679901; // double
 :geospatial_lon_max = -86.17833012089879; // double
 :Conventions = "_Coordinates";
 :format = "AR2V0003";
 :base_date = "2008-03-30";
 :time_coverage_start = "2008-03-30T13:18:26Z";
 :time_coverage_end = "2008-03-30T13:23:13Z";
 :history = "direct read of Nexrad Level 2 file into NetCDF-Java 2.2 API";
 :DataType = "Radial";
 :Title = "Nexrad Level 2 Station KPAH from 2008-03-30T13:18:24Z 
      to 2008-03-30T13:23:13Z";
 :Summary = "Weather Surveillance Radar-1988 Doppler (WSR-88D) Level II 
      data are the three meteorological base data quantities: reflectivity, 
      mean radial velocity, and spectrum width.";
 :keywords = "WSR-88D; NEXRAD; Radar Level II; reflectivity; mean radial 
      velocity; spectrum width";
 :VolumeCoveragePatternName = "16 elevation scans every 5 mins";
 :VolumeCoveragePattern = 11; // int
 :HorizonatalBeamWidthInDegrees = 1.5; // double
}



Legacy format example (pre Super-Res):
   
   netcdf /home/sansari/stage4/java/work/KGSP20070501_031016.nc {
 dimensions:
   scanR = 5;
   gateR = 460;
   radialR = 360;
   scanV = 5;
   gateV = 920;
   radialV = 360;
 variables:
   byte Reflectivity(scanR=5, radialR=360, gateR=460);
     :units = "dBZ";
     :long_name = "Reflectivity";
     :missing_value = 1b, 0b; // byte
     :signal_below_threshold = 0b; // byte
     :scale_factor = 0.5f; // float
     :add_offset = -33.0f; // float
     :_unsigned = "true";
     :range_folding_threshold = 50s; // short
     :_CoordinateAxes = "timeR elevationR azimuthR distanceR";
   int timeR(scanR=5, radialR=360);
     :long_name = "time since base date";
     :units = "msecs since 2007-05-01T03:10:16Z";
     :missing_value = -9999; // int
     :_CoordinateAxisType = "Time";
   float elevationR(scanR=5, radialR=360);
     :units = "degrees";
     :long_name = "elevation angle in degres: 0 = parallel to pedestal 
         base, 90 = perpendicular";
     :missing_value = NaNf; // float
     :_CoordinateAxisType = "RadialElevation";
   float azimuthR(scanR=5, radialR=360);
     :units = "degrees";
     :long_name = "azimuth angle in degrees: 0 = true north, 90 = east";
     :missing_value = NaNf; // float
     :_CoordinateAxisType = "RadialAzimuth";
   float distanceR(gateR=460);
     :units = "m";
     :long_name = "radial distance to start of gate";
     :_CoordinateAxisType = "RadialDistance";
   int numRadialsR(scanR=5);
     :long_name = "number of valid radials in this scan";
   int numGatesR(scanR=5);
     :long_name = "number of valid gates in this scan";
   byte RadialVelocity(scanV=5, radialV=360, gateV=920);
     :units = "m/s";
     :long_name = "Radial Velocity";
     :missing_value = 1b, 0b; // byte
     :signal_below_threshold = 0b; // byte
     :scale_factor = 0.5f; // float
     :add_offset = -64.5f; // float
     :_unsigned = "true";
     :range_folding_threshold = 50s; // short
     :_CoordinateAxes = "timeV elevationV azimuthV distanceV";
   int timeV(scanV=5, radialV=360);
     :long_name = "time since base date";
     :units = "msecs since 2007-05-01T03:10:16Z";
     :missing_value = -9999; // int
     :_CoordinateAxisType = "Time";
   float elevationV(scanV=5, radialV=360);
     :units = "degrees";
     :long_name = "elevation angle in degres: 0 = parallel to pedestal 
         base, 90 = perpendicular";
     :missing_value = NaNf; // float
     :_CoordinateAxisType = "RadialElevation";
   float azimuthV(scanV=5, radialV=360);
     :units = "degrees";
     :long_name = "azimuth angle in degrees: 0 = true north, 90 = east";
     :missing_value = NaNf; // float
     :_CoordinateAxisType = "RadialAzimuth";
   float distanceV(gateV=920);
     :units = "m";
     :long_name = "radial distance to start of gate";
     :_CoordinateAxisType = "RadialDistance";
   int numRadialsV(scanV=5);
     :long_name = "number of valid radials in this scan";
   int numGatesV(scanV=5);
     :long_name = "number of valid gates in this scan";
   byte SpectrumWidth(scanV=5, radialV=360, gateV=920);
     :units = "m/s";
     :long_name = "Spectrum Width";
     :missing_value = 1b, 0b; // byte
     :signal_below_threshold = 0b; // byte
     :scale_factor = 0.5f; // float
     :add_offset = -64.5f; // float
     :_unsigned = "true";
     :range_folding_threshold = 50s; // short
     :_CoordinateAxes = "timeV elevationV azimuthV distanceV";

 :Station = "KGSP";
 :StationName = "Greenville/Spartanburg/Greer,SC,US";
 :StationLatitude = 34.88333333333333; // double
 :StationLongitude = -82.22; // double
 :StationElevationInMeters = 287.0; // double
 :geospatial_lat_min = 32.81384387369406; // double
 :geospatial_lat_max = 36.952822792972604; // double
 :geospatial_lon_min = -84.74278844825646; // double
 :geospatial_lon_max = -79.69721155174354; // double
 :Conventions = "_Coordinates";
 :format = "AR2V0001";
 :base_date = "2007-05-01";
 :time_coverage_start = "2007-05-01T03:10:16Z";
 :time_coverage_end = "2007-05-01T03:19:45Z";
 :history = "direct read of Nexrad Level 2 file into NetCDF-Java 2.2 API";
 :DataType = "Radial";
 :Title = "Nexrad Level 2 Station KGSP from 2007-05-01T03:10:16Z 
      to 2007-05-01T03:19:45Z";
 :Summary = "Weather Surveillance Radar-1988 Doppler (WSR-88D) Level II 
      data are the three meteorological base data quantities: 
      reflectivity, mean radial velocity, and spectrum width.";
 :keywords = "WSR-88D; NEXRAD; Radar Level II; reflectivity; 
      mean radial velocity; spectrum width";
 :VolumeCoveragePatternName = "7 elevation scans every 10 mins";
 :VolumeCoveragePattern = 32; // int
 :HorizonatalBeamWidthInDegrees = 1.5; // double
}