Re: Help: about short2flt

From: Rick Brownrigg <brownrig_at_nyahnyahspammersnyahnyah>
Date: Tue Apr 13 2010 - 11:32:28 MDT

Also, as written, the line:

        sst = (/short2flt(sst)/)

will likely generate a "Assignment type mismatch..." error, as it
attempts to assign a float-array to a variable of type short. You'll
need a new variable (also, the (/.../) notation is not strictly
necessary):

        sstFlt = short2flt(sst)

On Apr 13, 2010, at 11:23 AM, Michael Notaro wrote:

> Be sure to load the contributed library.
> load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl"
>
>
>
> On Apr 13, 2010, at 12:14 PM, Kekuan Chu wrote:
>
>> Dear Sir/Madam:
>> I tried to convert short type array to float, with the following
>> command
>>
>> " filename = "amsr-avhrr-v2.20080910.nc"
>> in = addfile(filename,"r")
>> sst = in->sst(0,0,:,:)
>> sst = (/short2flt(sst)/)
>> sst = sst*0.01 "
>>
>> The error is:
>>
>> Copyright (C) 1995-2009 - All Rights Reserved
>> University Corporation for Atmospheric Research
>> NCAR Command Language Version 5.1.1
>> The use of this software is governed by a License Agreement.
>> See http://www.ncl.ucar.edu/ for more details.
>> fatal:Undefined identifier: (short2flt) is undefined, can't continue
>> fatal:Execute: Error occurred at or near line 11 in file plot_sst.ncl
>>
>>
>> How to handle this problem?
>> Thank you very much!
>>
>> BEST
>>
>> Kekuan Chu
>> 4/13/2010
>> _______________________________________________
>> 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

_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Tue Apr 13 11:32:36 2010

This archive was generated by hypermail 2.1.8 : Wed Apr 14 2010 - 09:15:22 MDT