[ncl-talk] Line plot for Ensemble mean, minimum and maximum value

Rick Brownrigg brownrig at ucar.edu
Fri Jun 7 10:44:47 MDT 2019


How about something like (untested):

dataDimsizes = dimsizes(data)
minMaxAvg = new((/3,dataDimsizes(1)/), typeof(data))
minMaxAvg(0,:) = dim_min_n(data, 0)
minMaxAvg(1,:) = dim_max_n(data, 0)
minMaxAvg(2,:) = dim_avg_n(data, 0)


Rick

On Fri, Jun 7, 2019 at 9:12 AM S Br <sbr.climate at gmail.com> wrote:

> Hi,
> I have created an array for time series data for 7 ensemble members. I
> would like to draw the lines for ensemble mean, minimum and maximum values.
> I can plot the individual ensemble members but not the mean, minimum and
> maximum values.
> Could you suggest how can I do this. The array I am creating is given
> below.
>
> data            = new((/7,1156/),float)
>   data(0,0:1155)  = temp1
>   data(1,0:1155)  = temp2
>   data(2,0:1155)  = temp3
>   data(3,0:1155)  = temp4
>   data(4,0:1155)  = temp5
>   data(5,0:1155)  = temp6
>   data(6,0:1155)  = temp7
>
>   time = ispan(850,2005,1)
>   time at long_name = "Time"
>
>  wks =  gsn_open_wks("X11", "Ensemble_Mean_timeseries")
>   res = True
>   res at xyXStyle               = "Time"
>   res at xyLineColors           =  (/ "green4", "red", "blue", "orange", \
>                                    "cyan2", "darkorchid2", "brown"/)
>
> ;-- create plot
>   plot = gsn_csm_xy(wks,time,data,res)
> _______________________________________________
> ncl-talk mailing list
> ncl-talk at ucar.edu
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20190607/67d5bc14/attachment.html>


More information about the ncl-talk mailing list