Skip to content

Commit

Permalink
fixes #1420
Browse files Browse the repository at this point in the history
  • Loading branch information
rhijmans committed Feb 6, 2024
1 parent 6670469 commit d3b5220
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions man/terrain.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,9 @@ If two cells have the same drop in elevation, a random cell is picked. That is n
Most terrain indices are according to Wilson et al. (2007), as in \href{https://gdal.org/programs/gdaldem.html}{gdaldem}. TRI (Terrain Ruggedness Index) is the mean of the absolute differences between the value of a cell and its 8 surrounding cells. TPI (Topographic Position Index) is the difference between the value of a cell and the mean value of its 8 surrounding cells. Roughness is the difference between the maximum and the minimum value of a cell and its 8 surrounding cells.
TRIriley (TRI according to Riley et al. (2007)) returns the square root of summed squared differences between the value of a cell and its 8 surrounding cells. TRIrmsd computes the square root of the mean of the squared differences between these cells. The benefit of TRIrmsd
TRIriley (TRI according to Riley et al., 2007) returns the square root of summed squared differences between the value of a cell and its 8 surrounding cells. TRIrmsd computes the square root of the mean of the squared differences between these cells.
Such measures can also be computed with the \code{\link{focal}} function:
These measures can also be computed with \code{\link{focal}} functions:
TRI <- focal(x, w=3, fun=\(x) sum(abs(x[-5]-x[5]))/8)
Expand Down

0 comments on commit d3b5220

Please sign in to comment.