Learn R Programming

spNetwork (version 0.2.1)

lines_points_along: Points along lines

Description

Generate points along the lines of a SpatialLinesDataFrame.

Usage

lines_points_along(lines, dist)

Arguments

lines

The SpatialLinesDataframe to use

dist

The distance between the points along the lines

Value

An object of class SpatialLinesDataframe (package sp)

Examples

Run this code
# NOT RUN {
networkgpkg <- system.file("extdata", "networks.gpkg", package = "spNetwork", mustWork = TRUE)
mtl_network <- rgdal::readOGR(networkgpkg,layer="mtl_network", verbose=FALSE)
new_pts <- lines_points_along(mtl_network,50)
# }

Run the code above in your browser using DataLab