ArcGis中栅格相关系数的计算
计算多个栅格的相关系数
※ARCGIS中,如果要计算两个栅格层的相关系数,在arctool box中,spatial analyst
tools->multivariate->band collection statistcs也可以实现统计功能,当然了多个栅格图
层需要采用Data Management Tools->Raster->composite bands把多个栅格图层复合成一个
文件,类似与grid中的MAKESTACK命令。 2000年1km数据与8km数据相关系数 # CORRELATION MATRIX # Layer 1 2
# --------------------------------------------------------------------------
1 1.00000 0.99383 2 0.99383 1.00000 #
=================================================================== 如果有安装worstation也可以实现上述功能:
情况一:
ARCGIS中,如果要计算两个栅格层的相关系数,可以采用ARC下的CORRELATION命令,其具体
的使用方式如下:
CORRELATION
{grid2} - an input integer or floating-point grid. If no second input grid is specified, the cross correlation will be performed on the first grid shifted on itself
by the specified offset.
{xoffset} - the number of cells in the x-axis or direction to offset the second input
grid from the first input grid. The default x-offset is zero cells. {yoffset} - the number of cells in the y-axis or direction to offset the second input
grid from the first input grid. The default y-offset is zero cells. 情况二:
ARCGIS中,如果要计算多于两个栅格层的相关系数,可以采用ATC下的STACKSTATS命令,其具
体使用方式如下:
STACKSTATS
calculated. {out_data_file} - name of the file where the results will be stored. By default, the results will be presented in tabular form on screen without saving them to an output file.
{BRIEF | DETAIL} - keywords specifying whether covariance and correlation matrices will be presented.
BRIEF - only the basic statistical measures: minimum, maximum, mean, and standard deviation will be calculated for every layer.
DETAIL - in addition to the standard statistics calculated with BRIEF, the covariance and correlation matrices will also be determined.
为了实现上述的功能,还需要把所有的栅格图层通过MAKESTACK命令生成一个STACK。
例子:以4个栅格数据为例,其统计结构包括基本统计量,协方差,相关系数 The example below shows the output from the STACKSTATS function for a four layer stack. The first table shows the basic statistics when the BRIEF option is used. However, when the DETAIL option is specified, as it is in the example below, the covariance and correlation matrices are also calculated. In the example, no {out_data_file} has been specified, therefore, the output statistics are automatically displayed to the screen.
Grid: stackstats helen4 # detail # STATISTICS of INDIVIDUAL LAYERS # Layer MIN MAX MEAN STD
# ------------------------------------------------------------ 1 1.0000 21.0000 7.8410 4.1690 2 1.0000 128.0000 25.5144 35.8494 3 296.9573 4073.6306 1565.5359 763.9803 4 0.3333 127.5000 51.5314 29.7958