[Thread Prev][Thread Next][Index]

How do I deal with variables without dimension

Hi ferret users,

I have daily mean wind velocity maps for several
months and I am working on calculating the
autocorrelation averaged on the whole grid, for
different lags in order to plot the mean
autocorrelation as a function of the lag. To do so, I
have written a script which computes the mean
autocorrelation for a specific lag. That script named
autocorrel.jnl works fine :

USE "../obs_era_uv.ctrl.nc"
go variance
let R=R_xmean[y=22.50S:22.50N@AVE]

Then I have another script which makes a loop over all
the lags I need and calls the previous script. Then
it's supposed to write the autocorrelation in a netcdf
file. Here is the script :

repeat/i=1:$1 (go autocorrel
`i`;save/file=output_autocorrel.nc/append `i`,R)

My problem is that I only get the autocorrelation of
the last lag written down : it seems my script writes
over the previous output data. I guess it is because
the variable R has no time dimension (and even no
dimension at all).

So my question is : How can you add a dimension to a
variable. Especially as I only have 1 value of
autocorrelation each step, it's not a list.

If you have any other way to get an output file with
the autocorrelation and its corresponding lag, I would
be really glad to hear your advice.



[Thread Prev][Thread Next][Index]

Dept of Commerce / NOAA / OAR / PMEL / TMAP

Contact Us | Privacy Policy | Disclaimer | Accessibility Statement