Data file formats - PowerPoint PPT Presentation

1 / 9
About This Presentation
Title:

Data file formats

Description:

do 20 var = 1, numvars. do 30 lev = 1, numlevels. nrec = nrec 1 write(1,rec=nrec)((array(time,var,lev,x,y),x=1,65),y=1,29) end do ... – PowerPoint PPT presentation

Number of Views:84
Avg rating:3.0/5.0
Slides: 10
Provided by: beth74
Category:
Tags: data | file | formats | var

less

Transcript and Presenter's Notes

Title: Data file formats


1
Data file formats
  • Handout
  • Common ones (to me, anyway)
  • ASCII (text)
  • Direct and Sequential binary
  • Metadata binary
  • netCDF (reanalysis)
  • HDF (JPLs Sea Surface data)
  • GRIB (NWS model output - GFS, Eta, etc.)

2
Intro to GrADS
  • Grid Analysis and Display System
  • Freeware from http//grads.iges.org/grads
  • Uses data formats of
  • Binary - need a control file
  • GRIB
  • netCDF
  • HDF/SDS (Scientific Data Sets)
  • Run on an X-term environment. Several
    executables
  • gradsc - for most binary, non-metadata files
  • gradsnc - for netCDF files

3
GrADS Basics
  • open, sdfopen (for netCDF)
  • display, d
  • set
  • clear

4
We Play!
  • Open the netCDF file globalnoa.nc in the
    transfer directory
  • UNIXgt gradsnc -l
  • GrADSgt sdfopen ../transfer/globalnoa.nc
  • query or q will list all parameters you can
    find out more about. Query the file just opened
  • GrADSgt q file
  • display or d will map out the variable
    desired
  • GrADSgt d slp
  • clear or c will clear the screen, but
    maintain some information such the current file
    that has been opened, spatial domain, temporal
    dimension, etc. Some parameters will be lost
    (well learn about this later)
  • GrADSgt c

5
We Play some more!
  • Modify dimensions (x, y, z, and t) using the
    set command.
  • Remove the dotted grid lines
  • Display SLP for April 1948
  • Display SLP for January 1992
  • Only display SLP for the area 0N to 80N and -80W
    to 10E
  • Display the cross-section of SLP at the 50N
    latitude

6
Binary files and GrADS
  • Need a control file for the binary file of
    data. Defines the dimensions (x,y,z,t) of the
    file
  • Examine the file mncep1985.ctl. This is for a
    GRIDDED data file
  • File create with the following priority
  • do 10 time 1, numtimesteps
  • do 20 var 1, numvars
  • do 30 lev 1, numlevels
  • nrec nrec 1
    write(1,recnrec)((array(time,var,lev,x,y),x1,65)
    ,y1,29)
  • end do
  • end do
  • end do

7
We Play!
  • Open the mncep1985.ctl file in GrADS
  • Query the file
  • Display a variable
  • Display another variable
  • Zoom in
  • Display a variable for June
  • Display 500mb geopotential heights
  • Display the vertical crosss-section of
    temperature at the 40N latitude

8
Station data and GrADS
  • Must also be binary
  • Must include latitude and longitude for each
    station location
  • If write out file in the following format
  • format(i4,i2,2x,a,2x,11f8.2)
  • Can run a program written by Greg McCurdy (WRCC)
    which converts your ASCII file to binary for
    GrADS grstnG.c
  • Also need a separate file for GrADS which is a
    station map file that corresponds to the station
    locations. stnmap is a GrADS program to create
    this file.
  • Examine the raws.ctl file

9
We Play!
  • Open the raws.ctl file in GrADS
  • Query the file
  • Display a variable
  • Zoom in to area of interest
  • Display another variable
Write a Comment
User Comments (0)
About PowerShow.com