Description Usage Arguments Details Value Author(s) See Also Examples
This function produces a grid over an specified area and then computes the frequency of lines that cross each cells' grid.
1 | RasterizeTraj(spLines, resolution=10000, reduce=TRUE, parallel=FALSE )
|
spLines |
An object of class SpatialLines created by the function |
resolution |
numeric vector of length 1 or 2 to set the resolution. If this argument is used, arguments ncols and nrows are ignored. |
reduce |
Boolean: If TRUE the result will be reduced to one raster object; if FALSE, this function will return a list of RasterLayer. The size of the list is equal to the number of available cores in the system. |
parallel |
Boolean: If TRUE, the rasterize process will be made in parallel. |
Because this function do all the process in parallel, it calls the function
SplitSpLines
and divides the spLines object into N sub sets of
Spatial Lines objects, where N is the number of cores availables in the System.
A Object of class RasterLayer or a list of objects RasterLayer.
Thalles Santos Silva
1 2 3 4 |
crs <- "+proj=longlat +datum=NAD83 +no_defs +ellps=GRS80 +towgs84=0,0,0"
air.traj.lines <- Df2SpLines(air.traj, crs)
raster.lines <- RasterizeTraj(air.traj.lines, reduce=TRUE, resolution=10000, parallel=FALSE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.