Hi Ryo and other ferreters..
My problem is not solved yet. Since i wanted to make calculations along
a slanted axis, i required to change my original model X and Y axis as a
slanted one.
So I divided my section into a number of lines(12) as shown in the
attached figure (ofcourse, i need more sections to take all the points..
this is just a sample) using samplexy command like this
let xlon0=80.5+0.25*I[I=1:30]
let ylat0=14+0.25*I[I=1:30]
...
....
let xlon12=80.5+0.25*I[I=1:32]
let ylat12=11.0+0.25*I[I=1:32]
let new_temp1=samplexy(SST,xlon0,ylat0)
......
......
let new_temp12=samplexy(SST,xlon12,ylat12)
As a result, i will get a 1D array like
(1,1),(1,2).......(1,30) for new_temp1
.................
..................
(1,1),(1,2).......(1,30) for new_temp12
As a result i cannot make a 2D(in newX and newY) plot from my above
values. I want to regrid the above as a 2D array having the value of SST
like below with a single variable name "TEMP"
(1,1),(1,2).......(1,30) var=TEMP ! in the first section
.................
..................
(12,1),(12,2).......(12,30) var=TEMP ! in the 12th section.
is it possible with ferret? If any of you know this.. could you please
teach me..?
Thanks in advance
Prescilla
On Sun, 2009-08-09 at 20:16 -1000, Ryo Furue wrote:
> Hi Prescilla,
>
> | I am in need to select a slanted domain as my region, as in the
> | attached figure.I wanted to to do my calculations within that domain
> | only. If any of you know how to manage a slanted domain(is there any
> | command?) selection using ferret, kindly teach me.
>
> Your domain seems to have a simple analytical definition using
> a set of inequalities such as "y - 2 * x + 30 > 0",
> where x is longitude and y is latitude.
> (This equality is just for an illustration purpose. Don't use it.)
> If so, you can "mask" your variables according to
> those inequalities. For example, if you want
> to extract the domain "(x + 2*y -100 > 0) and (x + 2*y -300 < 0)",
>
> yes? set data levitus_climatology
> yes? let masked_temp \
> = if (x + 2*y -300 lt 0 and x + 2*y -100 gt 0) then temp
> yes? fill/k=1 masked_temp
>
> Hope this helps,
> Ryo
Attachment:
rotate_regrid.jnl
Description: Binary data