Getting data in CDAT
![]() |
![]() |
![]() | |
| Contents | Previous | Next |
Goal: Learn how get data in CDAT.
There are multiple ways to retrieve data for self describing data file types.
All the data
You can get all of it, omitting dimensions are retrieving entire variable with the name 'var'
import cdms
f = cdms.open('sample.nc')
s = f(‘var’)
Specific dimension
You can specify dimension type and values
s = f(‘var’, time=(time1,time2))Known dimension types: time, level, latitude, longitude (t,z,y,x) .
Specific dimension names and values
s = f(‘var’,dimname1=(val1,val2))Sometimes indices are more useful than actual values
s = f(‘var’,time=slice(indice1,indice2,step))
![]() |
![]() |
![]() | |
| Contents | Previous | Next |


