Re: [netcdfgroup] new to list, new to netcdf

Robert Weaver asked:
> I am trying to find out if the ability exists to extract an array of 
> indices from a variable along one dimension. 
> For instance, I have variables that are 2 dimensional from the 
> unstructured model, one dimension is the nodal value and the other is 
> time. 
> Lets assume that I have queried an unstructured mesh for specified 
> locations (ie the nodal points within a specific Lat/Lon box), and saved 
> the indices of those locations to an array variable.  Does there exist a 
> means of passing that array of non-consecutive indices into 
> nf90_get_var, to extract those values.

No, sorry, there is no function that does what you want, even in
netCDF-4.

It would be relatively straightforward to write such a function that
used the single value interfaces for accessing variable values for each
index in the specified array, returning the resulting array of values.
If the indices in the array were sorted, it might not be too
inefficient, because it could take advantage of the read-ahead buffering
in the netCDF library.

--Russ



  • 2010 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the netcdfgroup archives: