Learn R Programming

TreeLS (version 2.0.2)

setTLS: (Re-)Create a LAS object depending on the input's type

Description

Reset the input's header if it is a LAS object, or generate a new LAS from a table-like input. For more information, checkout lidR::LAS.

Usage

setTLS(cloud, col_names = NULL)

Arguments

cloud

LAS, data.frame, matrix or similar object to be converted.

col_names

optional - character vector. Only used for table-like objects. It states the column names. If not set, only the 3 first columns will be used and assigned to the XYZ fields.

Value

LAS object.

Examples

Run this code
# NOT RUN {
cloud = matrix(runif(300, 0, 10), ncol=3)
cloud = setTLS(cloud)
summary(cloud)
# }

Run the code above in your browser using DataLab