Learn R Programming

lidR (version 4.1.0)

st_transform: Transform or convert coordinates of LAS objects

Description

Transform or convert coordinates of LAS objects st_transform() extends sf::st_transform()

Usage

# S3 method for LAS
st_transform(x, crs, ...)

Value

A LAS object

Arguments

x,

An object of class LAS

crs

crs object from sf or CRS object from sp

...

additional arguments scale and xoffset, yoffset, zoffset for the output LAS objects. It is not mandatory but recommended to consider providing such information. Otherwise it will be guessed automatically which might not be the best choice.

Examples

Run this code
LASfile <- system.file("extdata", "example.laz", package="rlas")
las = readLAS(LASfile)
st_crs(las)$Name
st_bbox(las)
tlas <- sf::st_transform(las, sf::st_crs(26918))
st_crs(tlas)$Name
st_bbox(tlas)

Run the code above in your browser using DataLab