Documentation for /home/davin/idl/socware/

Generated by IDLdoc

single page | use frames     summary     class     fields     routine details     file attributes

general/misc/

bin1d.pro


Routines

top source bin1D

bin1D, binarr, arrs2bin, minval, maxval, binwidth, kinbin, bincenters, averages, stdevs, medians, revarr=revarr, maxvarvec=maxvarvec, minvarvec=minvarvec, flag4nodata=flag4nodata

Procedure: bin1d Purpose: Uses histogram to bin data according to array binarr. The elements in binarr that are in a specific bin correspond to elements in other arrays (like density, temperature etc) and the averages of those are computed within each bin. The arrays to be averaged within each bin are passed in arrs2bin(NXM) where N is the number of elements of the binarr and M is the number of quantities. Output: kinbin is K-array of elements (K=number of bins) containing number of points within each bin, bincenters a K-array with center of bins, averages is KXM array with averages (zero if no points) stdevs an KXM array with stdevs about the mean and medians is KXM array of medians within each bin If any of the keywords maxvarvec or minvarvec is set to a name then it is assumed that the first two elements of the array "arrs2bin" correspond to the X,Y coordinates of a "flow" field. The corresponding data in each cell will be rotated in a max/min variance direction. The maxvariance direction will be in 2D vector maxvarvec for each cell. The minvariance direction will be in 2D vector minvarvec for each cell. The vector norm is the variance in the max/min direction, i.e., lambda_i=sqrt(maxvarvec(*,0)^2+maxvarvec(*,1)^2). if keyword flag4nodata is set, then points with no data are flags set equal to the value passed in, not zeros. Usage: ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; bin1D,Ygse,[[Ni],[Ti],[Vx],[fx],[Qx],[Eylep]],-15.,15.,1.,kinbin,Ycntrs,avrg,std,med Niavg=avrg(*,0)&Tiavg=avrg(*,1)&Vxavg=avrg(*,2)&fxavg=avrg(*,3)&Qxavg=avrg(*,4)&Eylepavg=avrg(*,5) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; $LastChangedBy: pcruce $ $LastChangedDate: 2007-10-03 14:49:09 -0700 (Wed, 03 Oct 2007) $ $LastChangedRevision: 1661 $ $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/idl_socware/trunk/external/IDL_GEOPACK/t01/t01.pro $

Parameters

binarr
arrs2bin
minval
maxval
binwidth
kinbin
bincenters
averages
stdevs
medians

Keywords

revarr
maxvarvec
minvarvec
flag4nodata

File attributes

Modification date: Thu Feb 13 16:43:48 2014
Lines: 59