Integrating variable plot radii in plot_metrics() #494
-
Hi everyone, For an ABA project I am currently working on I am trying to compute plot metrics using Thanks in advance and kind regards, Also: first time posting on GitHub, please excuse my lack of formatting. |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 3 replies
-
You can provide several radii (one per plot) plot_metrics(ctg, centers, radius = center$radius) |
Beta Was this translation helpful? Give feedback.
-
I hate asking about this again but I am still unsure about the metrics which were calculated. I have tried the following 4 lines:
I have checked a couple of calculated metrics, such as zmax, zmean, zsd, zpcum7 and zpcum8, and they seem to be the exact same for every different radius input. Do you have an idea about how this is happening? Sadly I cannot share my data with you. |
Beta Was this translation helpful? Give feedback.
-
This is not what I'm seeing with a reproducible example LASfile <- system.file("extdata", "Megaplot.laz", package="lidR")
las = readLAScatalog(LASfile)
col = sf::sf.colors(15)
shpfile <- system.file("extdata", "efi_plot.shp", package="lidR")
inventory <- sf::st_read(shpfile, quiet = TRUE)
inventory # contains an ID and a Value Of Interest (VOI) per plot
fun = ~list(q85 = quantile(Z, probs = 0.85))
m1 <- plot_metrics(las, fun, inventory, radius = 11.28)
m2 <- plot_metrics(las, fun, inventory, radius = runif(5, 5, 25))
plot(m1["q85"], pch = 19, cex = 3)
plot(m2["q85"], pch = 19, cex = 3)
m1$q85
#> [1] 21.4225 22.0655 23.0420 19.0825 14.9125
m2$q85
#> [1] 21.000 21.680 22.890 21.541 14.660 |
Beta Was this translation helpful? Give feedback.
You can provide several radii (one per plot)