La continuité du service gitlab.irstea.fr sera assurée en 2020. Nous envisageons ensuite une évolution vers une forge nationale INRAE encore à construire. Nous vous tiendrons au courant des évolutions futures.

Commit 2ae38ca6 authored by abc's avatar abc

Corrected mistake 2 in cloudTreeMetrics example

parent a0e2d0dc
......@@ -229,9 +229,9 @@ points2terrainStats <- function(p, centre=NULL, r=NULL)
#'
#' @param llasn list of LAS objects (from lidR package)
#' @param XY a dataframe or matrix with XY coordinates of plot centers
#' @param plot.radius numeric. plot radius in same unit as coordinates of LAS objects
#' @param plot.radius numeric. plot radius in meters
#' @param res numeric. resolution of canopy height model computed with \code{\link{points2DSM}} before tree segmentation
#' @param func a function to be applied to the attributes of extracted trees (return from internal call to treeExtraction function to compute plot level metrics
#' @param func a function to be applied to the attributes of extracted trees (return from internal call to \code{\link{treeExtraction}} function to compute plot level metrics
#' @param ... other parameters to be passed to \code{\link{treeSegmentation}}
#' @return a dataframe with tree metrics in columns corresponding to LAS objects of the list (lines)
#' @seealso \code{\link{treeSegmentation}}, \code{\link{treeExtraction}}, \code{\link{stdTreeMetrics}}
......@@ -255,7 +255,7 @@ points2terrainStats <- function(p, centre=NULL, r=NULL)
#' # number of detected trees between 20 and 30 meters and their mean height
#' user.func <- function(x, area.ha=NA)
#' {
#' dummy <- x$h[which(x$h>10 & x$h<20)]
#' dummy <- x$h[which(x$h>20 & x$h<30)]
#' data.frame(Tree.between.20.30=length(dummy)/area.ha, Tree.meanH=mean(dummy))
#' }
#' cloudTreeMetrics(llas, cbind(c(974350, 974390, 974350), c(6581680, 6581680, 6581640)), 10, res=0.5, func=user.func)
......
......@@ -7,7 +7,7 @@
BoxcoxTr(x, lambda)
}
\arguments{
\item{x}{vector. values to be transformed}
\item{x}{vector or RasterLayer. values to be transformed}
\item{lambda}{numeric. parameter of Box-Cox transformation}
}
......
......@@ -12,11 +12,11 @@ cloudTreeMetrics(llasn, XY, plot.radius, res = 0.5,
\item{XY}{a dataframe or matrix with XY coordinates of plot centers}
\item{plot.radius}{numeric. plot radius in same unit as coordinates of LAS objects}
\item{plot.radius}{numeric. plot radius in meters}
\item{res}{numeric. resolution of canopy height model computed with \code{\link{points2DSM}} before tree segmentation}
\item{func}{a function to be applied to the attributes of extracted trees (return from internal call to treeExtraction function to compute plot level metrics}
\item{func}{a function to be applied to the attributes of extracted trees (return from internal call to \code{\link{treeExtraction}} function to compute plot level metrics}
\item{...}{other parameters to be passed to \code{\link{treeSegmentation}}}
}
......@@ -49,7 +49,7 @@ cloudTreeMetrics(llas,
# number of detected trees between 20 and 30 meters and their mean height
user.func <- function(x, area.ha=NA)
{
dummy <- x$h[which(x$h>10 & x$h<20)]
dummy <- x$h[which(x$h>20 & x$h<30)]
data.frame(Tree.between.20.30=length(dummy)/area.ha, Tree.meanH=mean(dummy))
}
cloudTreeMetrics(llas, cbind(c(974350, 974390, 974350), c(6581680, 6581680, 6581640)), 10, res=0.5, func=user.func)
......
......@@ -7,7 +7,7 @@
iBoxcoxTr(x, lambda)
}
\arguments{
\item{x}{vector. values to be transformed}
\item{x}{vector or RasterLayer. values to be transformed}
\item{lambda}{numeric. parameter of Box-Cox transformation}
}
......
......@@ -7,7 +7,7 @@
iBoxcoxTrBiasCor(x, lambda, varmod)
}
\arguments{
\item{x}{vector. values to be ransformed}
\item{x}{vector or RasterLayer. values to be ransformed}
\item{lambda}{numeric. parameter of Box-Cox transformation}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment