An update on the solution to this problem:
There were two things: first was that the environment variable
UDUNITS_PATH was being set, and it was pointing to an invalid
directory. The "ut_calendar" function depends on a file in order to
work correctly, and by default, it looks for this file in
$NCARG_ROOT/lib/ncarg/udunits, unless UDUNITS_PATH is set.
Unsetting this caused the script to run without errors.
Second, the units were being set to "DAYS since 1992-10-14". Udunits
apparently doesn't like the uppercase "DAYS".
It seems to work if you change the units to "days since 1992-10-14".
I don't think case should matter here, though, so I'm going to look
into this. The surprising thing is that no warning or error
was issued out of "ut_calendar", and instead, a bunch of missing
values were returned.
--Mary
On Mon, 27 Oct 2008, Mary Haley wrote:
>
> Cecile,
>
> I need more information about how you are trying to
> call this function. Can you send me your NCL script?
>
> --mary
>
> On Mon, 27 Oct 2008, Cecile Dardel wrote:
>
>> Hello,
>>
>> I'm desperately trying to use the ut_calendar function. But I have the
>> following error message all the time :
>>
>> *fgets(): Is a directory
>> udunits(3): Error occurred at line 1
>> udunits(3): Couldn't read units-file "/usr/local/udunits-1.12.9/etc"
>> ./udunits: Couldn't initialize udunits(3) package
>> *
>> Do you know what I can do ?
>>
>> Thank you very much for your help.
>>
>> Cecile D.
>>
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Mon Oct 27 2008 - 16:21:23 MDT
This archive was generated by hypermail 2.2.0 : Tue Oct 28 2008 - 09:54:43 MDT