Learn R Programming

trip (version 1.1-1)

as.trip.SpatialLinesDataFrame: Coercion between trip objects and sp line objects

Description

coercion between classes

Usage

as.trip.SpatialLinesDataFrame(from)

Arguments

from
trip object

Examples

Run this code
d <- data.frame(x = 1:10, y = rnorm(10), tms = Sys.time() + 1:10, id = gl(2, 5))

coordinates(d) <- ~x+y

tr <- trip(d, c("tms", "id"))

as.trip.SpatialLinesDataFrame(tr)

as(tr, "SpatialLinesDataFrame")

Run the code above in your browser using DataLab