Hi Brice: Could you send me a complete example (with sample netCDF file
and perl source, pared down to essentials?
I'll take a look at it.
--Doug
dhunt@xxxxxxxx
Software Engineer
UCAR - COSMIC, Tel. (303) 497-2611
On Thu, 30 Jul 2009, Brice Lambi wrote:
Hello,
I'm having some problems reading character data from a netcdf file using
PDL::NetCDF. This is my example nc file (from ncdump):
netcdf testnc {
dimensions:
recNum = UNLIMITED ; // (3 currently)
char_len = 256 ;
variables:
char char_data(recNum, char_len) ;
char_data:long_name = "some char data" ;
data:
char_data =
"some char data 0",
"some char data 1",
"some char data 2" ;
}
I will call "get" like this:
$recn = $nc->dimsize("recNum");
$tmp = $nc->get("char_data", [0,0], [$recn, 256]);
print $tmp;
And this is the output I see:
[ 'some char data 0' '' '' '' ]
Why is it only getting the first value? I've verified that $recn is 3.
Any ideas?
Thanks,
Brice Lambi
_______________________________________________
netcdfgroup mailing list
netcdfgroup@xxxxxxxxxxxxxxxx
For list information or to unsubscribe, visit:
http://www.unidata.ucar.edu/mailing_lists/