-FillValue

Report or discuss software problems and other woes

Moderators: arango, robertson

Post Reply
Message
Author
jafar1979
Posts: 37
Joined: Sat Feb 18, 2012 6:51 pm
Location: inioas

-FillValue

#1 Unread post by jafar1979 »

dear
after running latte test successfully, i tried to plot its out put. i saw that every variable in history file, has _FillValue (equal to 1 e+37). i know that in latte test masking option is defined and results in land area should be NAN but would you please tell me what _FillValue do?

also i cant understand what its velocity component's cross sections plot say? i check their values by ncdump command and seen that for example max and min values for total u are 1.8326 and -2.4781 , respectively. but their plots are not match with this values and shows values in e+28 order :shock: . would you please tell e what happen :?: ?
cheers
jr

User avatar
kate
Posts: 4088
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: -FillValue

#2 Unread post by kate »

The masked values are not NaN, but rather some strange 1.e38 value picked to never be a valid value. You need to tell your plotting software to use a mask for anything equal to the _FillValue. ncdump and ncview know to do that.

jafar1979
Posts: 37
Joined: Sat Feb 18, 2012 6:51 pm
Location: inioas

Re: -FillValue

#3 Unread post by jafar1979 »

Dear kate
Thanks for your reply. I got NaN values when open history file with matlab by:

Code: Select all

ncdisp('ocean_his','u');
u=ncread('ocean_his','u')
But with ncdump it has some things like: -,-,-,
Sorry but I can not completely find what you say. I have plotted by csec and ccnt and checked salinity and temp's cross sections plots, they don’t have this problem like velocity plots. While third of them have _FillValue :?: :?: .
You mean that for velocity I should do you suggestion:
You need to tell your plotting software to use a mask for anything equal to the _FillValue.
Finally I really become appreciate you guide me how I can do that?
Yours truly
jafar
Attachments
salinity
salinity
sal.png (16.51 KiB) Viewed 2815 times
u component
u component
u.png (17.04 KiB) Viewed 2815 times

User avatar
kate
Posts: 4088
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: -FillValue

#4 Unread post by kate »

One difference between plotting T or S verses a velocity is that a velocity could be rotated to get the eastward component. In order to rotate it, you combine u and v values. Your software needs to do the right thing when combining these things near the land mask. Your choices are to look at the source code and fix it yourself or to submit a bug report to the maker of the software.

As for Matlab, I don't use it but it must have some ability to turn off plotting over some portion of the domain. That's what you want to engage over the land mask.

Post Reply