# create tree locations and heights
ref_trees <- cbind(c(1, 4, 3, 4, 2), c(1, 1, 2, 3, 4), c(15, 18, 20, 10, 11))
def_trees <- cbind(c(2, 2, 4, 4), c(1, 3, 4, 1), c(16, 19, 9, 15))
# tree matching
match1 <- tree_matching(ref_trees, def_trees)
# height regression
reg <- height_regression(ref_trees, def_trees, match1,
species = c("ABAL", "ABAL", "FASY", "FASY", "ABAL"),
asp = 1, xlim = c(0, 21), ylim = c(0, 21)
)
summary(reg$lm)
reg$stats
Run the code above in your browser using DataLab