This function can be used to find the mean value for all the cells found within the defined disk area of a grid (all cell values are added together and then divided by the total number of cells that make up the disk), as shown in the image below:
ds_grid_get_disk_mean(index, xm, ym, r);
参数 | 描述 |
---|---|
index | 栅格的索引 |
xm | 栅格内圆盘区域x位置。 |
ym | 栅格内圆盘区域的y位置。 |
r | 栅格中圆盘的半径 |
Real or String
val = ds_grid_get_disk_mean(grid, 5, 5, 2)
The above code will set the variable "val" to the mean value contained within the given disk of the ds_grid indexed in the variable "grid".