blockmean(1gmt)


NAME

   blockmean - Block average (x, y, z) data tables by L2 norm

SYNOPSIS

   blockmean [ table ]
    -Iincrement
    -Rregion  [   -C  ]  [   -E[p]  ]  [   -S[m|n|s|w]  ] [  -V[level] ] [
   -W[i|o][+s] ] [ -bbinary ] [ -dnodata ] [ -fflags ]  [  -hheaders  ]  [
   -iflags ] [ -oflags ] [ -r ] [ -:[i|o] ]

   Note:  No  space  is allowed between the option flag and the associated
   arguments.

DESCRIPTION

   blockmean reads arbitrarily  located  (x,y,z)  triples  [or  optionally
   weighted  quadruples  (x,y,z,w)]  from  standard  input  [or table] and
   writes to standard output a mean position and value for every non-empty
   block  in  a  grid  region  defined  by the -R and -I arguments. Either
   blockmean, blockmedian, or blockmode should be used as a  pre-processor
   before  running  surface  to  avoid  aliasing  short wavelengths. These
   routines are also generally useful for decimating or averaging  (x,y,z)
   data.  You can modify the precision of the output format by editing the
   FORMAT_FLOAT_OUT parameter in your gmt.conf file,  or  you  may  choose
   binary input and/or output to avoid loss of precision.

REQUIRED ARGUMENTS

   -Ixinc[unit][=|+][/yinc[unit][=|+]]
          x_inc  [and  optionally  y_inc] is the grid spacing. Optionally,
          append a suffix modifier.  Geographical  (degrees)  coordinates:
          Append  m  to indicate arc minutes or s to indicate arc seconds.
          If one of the units e, f, k, M, n or u is appended instead,  the
          increment  is  assumed  to  be  given  in meter, foot, km, Mile,
          nautical mile or US  survey  foot,  respectively,  and  will  be
          converted  to  the  equivalent  degrees  longitude at the middle
          latitude   of   the   region   (the   conversion   depends    on
          PROJ_ELLIPSOID). If y_inc is given but set to 0 it will be reset
          equal to x_inc;  otherwise  it  will  be  converted  to  degrees
          latitude.   All   coordinates:   If   =  is  appended  then  the
          corresponding max x (east) or y (north) may be slightly adjusted
          to fit exactly the given increment [by default the increment may
          be adjusted slightly to fit the given domain]. Finally,  instead
          of  giving  an  increment  you  may  specify the number of nodes
          desired by appending + to the  supplied  integer  argument;  the
          increment  is then recalculated from the number of nodes and the
          domain. The resulting increment value  depends  on  whether  you
          have  selected  a  gridline-registered or pixel-registered grid;
          see App-file-formats for details. Note:  if  -Rgrdfile  is  used
          then  the  grid  spacing has already been initialized; use -I to
          override the values.

   -R[unit]xmin/xmax/ymin/ymax[r] (more ...)
          Specify the region of interest.

OPTIONAL ARGUMENTS

   table  3 [or 4, see -W] column ASCII data table file(s) [or binary, see
          -bi]  holding (x,y,z[,w]) data values. [w] is an optional weight
          for the data. If no file is specified, blockmean will read  from
          standard input.

   -C     Use the center of the block as the output location [Default uses
          the mean location].

   -E[p]  Provide Extended report which includes s (the standard deviation
          about  the mean), l, the lowest value, and h, the high value for
          each  block.  Output  order  becomes  x,y,z,s,l,h[,w].  [Default
          outputs  x,y,z[,w].  See  -W  for  w  output.  If -Ep is used we
          assume  weights  are  1/(sigma  squared)  and  s   becomes   the
          propagated error of the mean.

   -S[m|n|s|w]
          Use -Sn to report the number of points inside each block, -Ss to
          report the sum of all z-values inside a block, -Sw to report the
          sum of weights [Default (or -Sm reports mean value].

   -V[level] (more ...)
          Select verbosity level [c].

   -W[i|o][+s]
          Weighted  modifier[s]. Unweighted input and output has 3 columns
          x,y,z; Weighted i/o has 4 columns x,y,z,w.  Weights can be  used
          in  input  to  construct  weighted mean values in blocks. Weight
          sums can be reported in output for later combining several runs,
          etc.  Use  -W for weighted i/o, -Wi for weighted input only, -Wo
          for weighted output only. [Default uses unweighted i/o]. If your
          weights are actually uncertainties (sigma) then append +s and we
          compute weight = 1/sigma.

   -bi[ncols][t] (more ...)
          Select native binary input. [Default is 3 (or 4 if -Wi is set)].

   -bo[ncols][type] (more ...)
          Select native binary output. [Default is  3  (or  4  if  -Wo  is
          set)].  -E  adds 3 additional columns.  The -Sn option will work
          with only 2 input columns (x and y).

   -d[i|o]nodata (more ...)
          Replace input columns that equal nodata  with  NaN  and  do  the
          reverse on output.

   -f[i|o]colinfo (more ...)
          Specify data types of input and/or output columns.

   -h[i|o][n][+c][+d][+rremark][+rtitle] (more ...)
          Skip or produce header record(s).

   -icols[l][sscale][ooffset][,...] (more ...)
          Select input columns (0 is first column).

   -ocols[,...] (more ...)
          Select output columns (0 is first column).

   -r (more ...)
          Set  pixel node registration [gridline]. Each block is the locus
          of points nearest the grid value  location.  For  example,  with
          -R10/15/10/15  and  -I1:  with the -r option 10 <= (x,y) < 11 is
          one of 25 blocks; without it 9.5 <= (x,y) < 10.5 is  one  of  36
          blocks.

   -:[i|o] (more ...)
          Swap 1st and 2nd column on input and/or output.

   -^ or just -
          Print  a  short  message  about  the syntax of the command, then
          exits (NOTE: on Windows use just -).

   -+ or just +
          Print  an  extensive  usage  (help)   message,   including   the
          explanation  of  any  module-specific  option  (but  not the GMT
          common options), then exits.

   -? or no arguments
          Print a complete usage (help) message, including the explanation
          of options, then exits.

ASCII FORMAT PRECISION

   The ASCII output formats of numerical data are controlled by parameters
   in your gmt.conf file. Longitude and latitude are  formatted  according
   to  FORMAT_GEO_OUT,  whereas  other  values  are formatted according to
   FORMAT_FLOAT_OUT. Be aware that the format in effect can lead  to  loss
   of  precision  in  the  output,  which  can  lead  to  various problems
   downstream.  If  you  find  the  output  is  not  written  with  enough
   precision,  consider  switching  to binary output (-bo if available) or
   specify more decimals using the FORMAT_FLOAT_OUT setting.

EXAMPLES

   To find 5 by 5  minute  block  mean  values  from  the  ASCII  data  in
   hawaii.xyg, run

          gmt blockmean hawaii.xyg -R198/208/18/25 -I5m > hawaii_5x5.xyg

SEE ALSO

   blockmedian,   blockmode,  gmt,  gmt.conf,  greenspline,  nearneighbor,
   sphtriangulate, surface, triangulate

COPYRIGHT

   2016, P. Wessel, W. H. F. Smith, R. Scharroo, J. Luis, and F. Wobbe





Opportunity


Personal Opportunity - Free software gives you access to billions of dollars of software at no cost. Use this software for your business, personal use or to develop a profitable skill. Access to source code provides access to a level of capabilities/information that companies protect though copyrights. Open source is a core component of the Internet and it is available to you. Leverage the billions of dollars in resources and capabilities to build a career, establish a business or change the world. The potential is endless for those who understand the opportunity.

Business Opportunity - Goldman Sachs, IBM and countless large corporations are leveraging open source to reduce costs, develop products and increase their bottom lines. Learn what these companies know about open source and how open source can give you the advantage.





Free Software


Free Software provides computer programs and capabilities at no cost but more importantly, it provides the freedom to run, edit, contribute to, and share the software. The importance of free software is a matter of access, not price. Software at no cost is a benefit but ownership rights to the software and source code is far more significant.


Free Office Software - The Libre Office suite provides top desktop productivity tools for free. This includes, a word processor, spreadsheet, presentation engine, drawing and flowcharting, database and math applications. Libre Office is available for Linux or Windows.





Free Books


The Free Books Library is a collection of thousands of the most popular public domain books in an online readable format. The collection includes great classical literature and more recent works where the U.S. copyright has expired. These books are yours to read and use without restrictions.


Source Code - Want to change a program or know how it works? Open Source provides the source code for its programs so that anyone can use, modify or learn how to write those programs themselves. Visit the GNU source code repositories to download the source.





Education


Study at Harvard, Stanford or MIT - Open edX provides free online courses from Harvard, MIT, Columbia, UC Berkeley and other top Universities. Hundreds of courses for almost all major subjects and course levels. Open edx also offers some paid courses and selected certifications.


Linux Manual Pages - A man or manual page is a form of software documentation found on Linux/Unix operating systems. Topics covered include computer programs (including library and system calls), formal standards and conventions, and even abstract concepts.