validate_sl_stand: Validate a SamsaRaLight stand object

View source: R/create_sl_stand.R

validate_sl_standR Documentation

Validate a SamsaRaLight stand object

Description

This function checks the internal consistency and structure of an object of class "sl_stand", as returned by create_sl_stand. It verifies that all required components are present and correctly formatted, that the embedded tree inventory conforms to the rules enforced by check_inventory, and that all trees and sensors are within the stand limits.

Usage

validate_sl_stand(x)

Arguments

x

An object expected to be of class "sl_stand".

Details

The following validations are performed:

  • The object inherits from class "sl_stand".

  • The top-level components trees, sensors, cells, core_polygon, transform, geometry and inventory are present.

  • The trees data.frame passes check_inventory.

  • The sensors data.frame passes check_sensors.

  • The cells data.frame contains columns x_center, y_center, z_center, and id_cell.

  • The geometry list contains cell_size, n_cells_x, n_cells_y, slope, aspect, and north2x.

  • All trees and sensors lie within the bounds of the rectangular stand.

Value

Invisibly returns TRUE if the stand is valid.

See Also

create_sl_stand, check_inventory, check_sensors, run_sl


SamsaRaLight documentation built on April 16, 2026, 5:08 p.m.