tiagodc / TreeLS

R functions for processing individual tree TLS point clouds
GNU General Public License v3.0
82 stars 27 forks source link

stem points making making up a stem segment #23

Closed mansi-aggarwal-2504 closed 4 years ago

mansi-aggarwal-2504 commented 4 years ago

The stemSegmentation method returns a data.table which also has N i.e. number of points belonging to the stem segment. We are getting the tree points, but how will I get these stem points (x,y,z) that make up the segment?

The previous stemPoints method use to return a las object with a TreeID column and whichever point was a stem point, a TreeID (natural number) would be allotted to it, else it would be zero.

How do I retrieve these stem point now?

tiagodc commented 4 years ago

The stemPoints method adds a boolean Stem field to your las@data, so if you want to retrieve only stem points from a specific TreeID you just combine those two fields, e.g. filter_poi(las, Stem & TreeID == any_tree_id)