[Thread Prev][Thread Next][Index]

Re: [ferret_users] problem with 'SAMPLEXY'



Thank you Jaison,
Please see the script I used to pick out winds from QSCAT 2006. I've copied it from the original; it doesnt give any errors while
running in ferret. The version I use is Ferret 6.00

The time axis for Latitude & Longitude is 21-JUL-2005 to 10-AUG-2007, out which I select my region of interest, 2006. Wind has values from Jan-Dec 2006. Latitude, Longitude & wind are daily data.

-----
let xpts_jandec = long[d=1,t="01-jan-2006:00:00":"31-dec-2006:00:00"]
let ypts_jandec = latd[d=1,t="01-jan-2006:00:00":"31-dec-2006:00:00"]
let winds_jandec = SAMPLEXY(ws,xpts_jandec,ypts_jandec)

let xpts_mayoct = long[d=1,t="01-may-2006:00:00":"31-oct-2006:00:00"]
let ypts_mayoct = latd[d=1,t="01-may-2006:00:00":"31-oct-2006:00:00"]
let winds_mayoct = SAMPLEXY(ws,xpts_mayoct,ypts_mayoct)
----

2.  The variables winds_jandec & winds_jandec, have the following grids:

yes? sh da
 name     title                             I         J         K         L
 WINDS_JANDEC
          SAMPLEXY(WS,XPTS_JANDEC,YPTS_JA  1:365     ...       ...       1:365
  (T=31-DEC-2005 12:00:31-DEC-2006 12:00)
 WINDS_MAYOCT
          SAMPLEXY(WS,XPTS_MAYOCT,YPTS_MA  1:184     ...       ...       1:365
  (T=31-DEC-2005 12:00:31-DEC-2006 12:00)


3.  The difference in winds_mayoct & winds_jandec (when i=1 is chosen) is
    shown below.

yes? li/t="01-may-2006:00:00":"08-may-2006:00:00" winds_jandec[i=1],winds_mayoct[i=1]
 Column  1: WINDS_JANDEC is SAMPLEXY(WS,XPTS_JANDEC,YPTS_JANDEC)
 Column  2: WINDS_MAYOCT is SAMPLEXY(WS,XPTS_MAYOCT,YPTS_MAYOCT)
                WINDS_JANDEC  WINDS_MAYOCT
01-MAY-2006 00 / 121:   2.159   4.868
02-MAY-2006 00 / 122:   2.909   4.673
03-MAY-2006 00 / 123:   3.565   4.913
04-MAY-2006 00 / 124:   4.141   5.081
05-MAY-2006 00 / 125:   4.918   5.536
06-MAY-2006 00 / 126:   5.265   5.638
07-MAY-2006 00 / 127: 5.223 5.834 08-MAY-2006 00 / 128: 6.139 6.394

Additionally, the longitude & latitude values for the corresponding days are: 01-MAY-2006 00 / 285: 88.79 15.40
02-MAY-2006 00 / 286:   88.74   15.42
03-MAY-2006 00 / 287:   88.71   15.45
04-MAY-2006 00 / 288:   88.67   15.47
05-MAY-2006 00 / 289:   88.64   15.50
06-MAY-2006 00 / 290:   88.60   15.53
07-MAY-2006 00 / 291:   88.56   15.55
08-MAY-2006 00 / 292:   88.52   15.57
Both xpts_jandec & xpts_mayoct (ypts_jandec & ypts_mayoct) list the same values.

Hope the problem is better conveyed this time.
thanks
Sindu



On Fri, 4 Jul 2008, jaison@xxxxxxxxxxxxxx wrote:

Hi Sindu,
         Setting region/selecting xpts and ypts along time for SAMPLEXY
input should work just fine, unless and otherwise there is something wrong
with your time axis (or it can be a bug with SAMPLEXY...but hold on...).
However, I will be really surprised if the given script has worked without
any error. Because :

     1. Ferret (or any similar tools) will not allow minus sign (-) in
           variable name, since it is a "special operator/symbol". Ferret
           refers such names as "illegal" (please see user manual,
           Ch3 Sec1.2. File variables, for example), as shown below

           yes? let xpts_jan-dec = 100
                **ERROR: command syntax: illegal name: XPTS_JAN-DEC
           yes?

     2. The time region syntax is wrong (double quotes are not closed).

So, please do the following :

   - make sure the time axes of lon, lat and wind variables are ok, and
         matches well (number of points, dates etc.)
   - define variables without minus sign (xpts_dec2jan, ypts_dec2jan.....)
   - demonstrate the error with listing few values
   - send a mail back with all details, demonstrating the error.

If you are providing lines from your script, please make sure that you
are making an exact copying. With these details, we can have a better
idea about the problem....and a better solution!

Thanks and Regards,

Jaison



Dear Ferreters,
I'm facing a problem with the function SAMPLEXY as I use it to pick out
values from a gridded dataset (eg wind speed).

I have xpts and ypts from Jan-Dec and I select the lat,lon points
in 2 ways: 1) Jan-Dec and 2) May-Oct.

The wind values I obtain when I select xpts & ypts from Jan-Dec are
different from when they are selected only for May-Oct.
Please see my script below.

1. Why isnt the wind during May-Oct in both cases identical? &
2. Why does the May-Oct selection give me wind data from Jan-Dec?

Am I missing something important while selecting the lat and
lon points in time and using it in combination with SAMPLEXY ?

Thanks
Sindu

------ script-----------------------------------------------

let xpts_jan-dec = longitude[t="01-jan-2006:00:00":"31-dec-2006:00:00]
let ypts_jan-dec =  latitude[t="01-jan-2006:00:00":"31-dec-2006:00:00]
let winds_jan-dec = SAMPLEXY(wind,xpts_jan-dec,ypts_jan-dec)

let xpts_may-oct = longitude[t="01-may-2006:00:00":"31-oct-2006:00:00]
let ypts_may-oct =  latitude[t="01-may-2006:00:00":"31-oct-2006:00:00]
let winds_may-oct = SAMPLEXY(wind,xpts_may-oct,ypts_may-oct)

------ script-----------------------------------------------


Sindu Raj Parampil
Ph.D Student
Centre for Atmospheric and Oceanic Sciences
Indian Institute of Science
Bangalore-12
INDIA
=========================================================================
"You don't understand anything until you learn it more than one way."
                                    Marvin Minsky, 'The Society of Mind'
=========================================================================





--

Sindu Raj Parampil
Ph.D Student
Centre for Atmospheric and Oceanic Sciences
Indian Institute of Science
Bangalore-12
INDIA
=========================================================================
"You don't understand anything until you learn it more than one way."
                                   Marvin Minsky, 'The Society of Mind'
=========================================================================


--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.



[Thread Prev][Thread Next][Index]

Contact Us
Dept of Commerce / NOAA / OAR / PMEL / TMAP

Privacy Policy | Disclaimer | Accessibility Statement