>I'm trying to compute a vertical weighted average of temperature and
>relative humidity from AIRS data (ntime,klev,nlat,mlon). The problem
>is that I need only "subcloud" conditions (cloud bottom pressure is
>obtained from visst data) hence the integration limits are variable
>in space.
>
>Does anyone know if the function wgt_vert_avg_beta will do the job,
>provided I set all values above cloud bottom to _FillValue?
---- Yes ... but [a] clarification Beta factors are used so that *all* integrations will have constant limits of integration. See the articles in the Description section of the vibeta function. http://www.ncl.ucar.edu/Document/Functions/Built-in/vibeta.shtml [b] implementions in your application The vibeta function was written for the situation where where psfc varies from grid-point to grid-point but ptop is constant. In your case, *both* psfc and ptop vary. I think you will have to do an "end around". Unfortunately, this could slow because you will have to loop. vint = new ( (/ntim,nlat,mlon/), typeof(x), getfillvalue(x) ) do nt=0,ntim-1 do nl=0,nlat-1 do ml=0,mlon-1 vint(nt,nl,ml) = vibeta (p,x(nt,:,nl,ml),linlog \ ,psfc(nt,n;,ml),pbot,ptop(nt,nl,ml)) end do end do end do The reson for this is to correctly handle the beta factor for the cloud level. good luck D _______________________________________________ ncl-talk mailing list ncl-talk_at_ucar.edu http://mailman.ucar.edu/mailman/listinfo/ncl-talkReceived on Wed Mar 21 2007 - 14:42:26 MDT
This archive was generated by hypermail 2.2.0 : Thu Mar 22 2007 - 09:26:28 MDT