[Thread Prev][Thread Next][Index]
Re: [ferret_users]plotting transect along the deepest depth (i.e thalweg)
Hi Murat,
Two questions :
1. What exactly is your problem? (Or what was the error message or
difficulty that you have faced?)
2. While finding kzero, what the "I=1:`temperature,RETURN=iend`@max"
stands for? If you intend to do the a similar operation on X
axis, you have to repeat all the steps for X-axis too.
The example given in the webpage you have mentioned is working fine for
me. The procedure is explained step by step below :
---> let kvals = k[g=temp] + temp * 0
This step will create a new variable "kvals", with following features
- XYZT grid will be EXACTLY same as that of "temp"
- at each and every grid point, the value of kvals will be the
level number (K-index) corresponding to the grid point
- Missing values will be EXACTLY as in "temp"
Example : yes? use levitus_climatology
yes? let kvals = k[g=temp] + temp * 0
yes? list/x=80/y=10 temp, kvals
---> let kzero = kvals - kvals[k=1:`temp,return=kend`@MAX]
This step will create a new variable kzero with following features
- XYZT grid same as that of temp or kvals
- will have zero value along Z-axis, ONLY at the deepest depth
Example : After the lines in above above example, issue :
yes? kzero = kvals - kvals[k=1:`temp,return=kend`@MAX]
yes? list/x=80/y=10 temp, kvals, kzero
---> let integrand = temp * kzero[k=@WEQ:0]
kzero[k=@WEQ:0] will return 1 if it finds a zero value exactly on
a point along Z-axis, else it will return the "weights" to get
zero, with missing values in all other Z-points. See User
Manual, Ch3 Sec2.4.27. @WEQ for details.
Example : list/x=80/y=10 temp, kvals, kzero, kzero[k=@WEQ:0]
When you multiply temp with kzero[k=@WEQ:0], the resulting variable
will have valid data ONLY on those points where kzero[k=@WEQ:0]
have "non-misssing" values. Now it can be directly SUMMED to get
the desired variable
Example : yes? let integrand = temp * kzero[k=@WEQ:0]
yes? plot integrand[k=@SUM,x=150]
Hope this helps,
Regards,
Jaison
On Tue, 19 Jun 2007, Murat Gunduz wrote:
>
> Dear Ferret Users,
>
> I would like to make a transect plot of temperature (from south to north)
> following the deepest depth from my 3D netcdf file.
>
> I have searched the e-mail list, but I could not find any clue.
> I tried to modify the one of the script in FAQ, but without success
> http://ferret.wrc.noaa.gov/Ferret/FAQ/analysis/deepest_depth.html
>
>
> my simple script is below,
>
> use temperature_3z.nc
> LET kvals = k[G=temperature] + 0*temperature
> let kzero = kvals -
> kvals[K=1:`temperature,RETURN=kend`@MAX,I=1:`temperature,RETURN=iend`@max]
> LET integrand = TEMPERATURE* kzero[k=@WEQ:0]
>
>
>
> Could you please help, how can I generate 2D transect along the thalweg?
> Thank you very much in advance.
>
> Murat Gunduz
>
>
>
>
>
>
>
>
>
--
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