netcdfjs icon indicating copy to clipboard operation
netcdfjs copied to clipboard

help in reading different dimensions of variables

Open pomarc opened this issue 7 years ago • 6 comments

Hello, thanks for the great module. I must read some variables of the Geo2D type. Each variable has 3 dimensions: Time, south_north, west_east. e.g:

float MYVAR(Time=73, south_north=80, west_east=100);
  :units = "ppb vol";
  :long_name = "MYVAR";

how can I read each variable point? If I use reader.getDataVariable("MYVAR") I get a single array of 73 elements, which I suppose is a slice of the data.

Can you please post an example about how I can get the remaining data points? thank you.

pomarc avatar Jan 05 '17 09:01 pomarc

Hello @pomarc, thanks for using our module! I think that's related with the issue #3, I'm still checking it out, I'm sorry for the delay

maasencioh avatar Jan 05 '17 22:01 maasencioh

Would also love to be able to read multiple dimensions with this library! I've made a fork of this project where I implemented some changes that enable me to read multiple dimensions (for my very specific case) but I would love to see a more generic solution as well :)

oldbram avatar Feb 23 '17 10:02 oldbram

Hello @pomarc, could you please test if you still have this issue?

maasencioh avatar Jun 09 '17 13:06 maasencioh

Hi @maasencioh , I'm also having a problem with this. If I pass in the variable name to getDataVariable() I only get back a single dim array and not a multi dim array.

Upon further inspection, the one slice of data doesn't actually look like it is correct:

Uploaded to the browser, one dimension array with strange data: screen shot 2018-03-28 at 1 22 00 pm

Opened with Panoply (NASA): screen shot 2018-03-28 at 1 23 06 pm

maka-io avatar Mar 28 '18 14:03 maka-io

Hello @maka-io, did you tried with the v0.3.1? can you share somehow your test file?

maasencioh avatar Apr 02 '18 16:04 maasencioh

Hi @maasencioh, I am using 0.3.1. I'm not at liberty to share the dataset, however, you should see a similar result with any such (HYCOM?) dataset.

maka-io avatar Apr 16 '18 14:04 maka-io