brandonmayer-zz / sci-wms

SCI-WMS: A Python WMS service for geospatial gridded data (Only triangular unstructured meshes and logically rectangular grids officially supported at this time)
http://asascience-open.github.io/sci-wms
GNU General Public License v3.0
1 stars 0 forks source link

util class to get variable by standard_name #3

Closed brianmckenna closed 10 years ago

brianmckenna commented 10 years ago

example

import netCDF4
from sciwms.util import cf

url = 'http://comt.sura.org/thredds/dodsC/data/comt_1_archive/inundation_tropical/UND_ADCIRC/Hurricane_Ike_2D_final_run_with_waves'

nc = netCDF4.Dataset(url,'r')

# get by CF compliant standard_name
v = cf.get_by_standard_name(nc,'sea_surface_height_above_geoid')

print v