Description Usage Arguments References Examples
This function runs the Modified Fast Marching Method of Silva and Steele (2012,2014) from sp and raster objects and outputs results in the same formats, making it more convenient for (geo)spatial analyses and simulation.
1 | spFastMarch(domain, seeds, spatial.res, verbose = T)
|
domain |
A |
seeds |
A |
spatial.res |
(Optional) Spatial resolution of the raster, necessary only to correct the rate-of-spread unit. Defaults to that of the raster used for domain. |
verbose |
(Optional) Boolean to control verbose output. |
Sethian, J.A. (1996), A fast marching level set method for monotonically advancing fronts, Proc. Natl. Acad. Sci. 93 (4), 1591-1595, doi:
Silva, F. and Steele, J. (2012), Modeling Boundaries Between Converging Fronts in Prehistory, Advances in Complex Systems, 15(1-2), 1150005, doi: 10.1142/S0219525911003293
Silva, F. and Steele, J. (2014), New methods for reconstructing geographical effects on dispersal rates and routes from large-scale radiocarbon databases, Journal of Archaeological Science 52, 609-620, doi: 10.1016/j.jas.2014.04.021
1 2 3 4 5 6 7 8 9 10 11 12 | library(raster); library(sp); library(rgdal)
domain <- raster(system.file("external/test.grd", package="raster")) # sample raster
domain <- domain > 0 # flattening elevation data
coords <- cbind(c(179000,181200), c(330000, 333000)) # coordinates for seeds
seed.df <- data.frame(incept=c(0,10), speed=c(.1,.1)) # incept time and speed for each seed
seeds <- SpatialPointsDataFrame(coords, seed.df, proj4string=crs(domain))
fm <- spFastMarch(domain, seeds, verbose=FALSE)
par(mfrow=c(1,3))
plot(fm$process, main='process')
plot(fm$arrival.time, main='arrival time')
plot(fm$cost.distance, main='distance')
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.