hf_velocity: General hiking function for velocity

Description Usage Arguments Value Examples

View source: R/hf_velocity.R

Description

A convenience wrapper for generating a velocity (distance per unit time) raster based on various hiking functions.

Usage

1
hf_velocity(x, hf = "tobler", ...)

Arguments

x

A RasterLayer with slope values, assumed to be in degrees.

hf

Character The hiking function with which to compute velocity, either "tobler" (default) or "campbell."

...

Arguments to be passed to individual hiking functions.

Value

A RasterLayer of velocity values in km/hr.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
## Not run: 

library(raster)

dem <- raster(system.file("extdata/slc.tif", package = "rHike"))

slope <- hf_slope(dem)

tobler <- hf_velocity(slope, hf = "tobler", on.path = TRUE)
campbell <- hf_velocity(slope, hf = "campbell", decile = 30)

plot(stack(tobler, campbell))


## End(Not run)

kbvernon/rHike documentation built on May 29, 2020, 7:22 p.m.