CloudMetrics: FUSION R command line interface - Computes metrics describing...

View source: R/CloudMetrics.R

CloudMetricsR Documentation

FUSION R command line interface – Computes metrics describing an entire point cloud.

Description

CloudMetrics creates command lines for the FUSION CloudMetrics program and optionally executes them.

Usage

CloudMetrics(
  inputspecifier = NULL,
  outputfile = NULL,
  quiet = FALSE,
  verbose = FALSE,
  version = FALSE,
  newlog = FALSE,
  log = NULL,
  locale = FALSE,
  nolaszipdll = FALSE,
  skipfilecheck = FALSE,
  above = NULL,
  new = FALSE,
  firstinpulse = FALSE,
  firstreturn = FALSE,
  first = FALSE,
  highpoint = FALSE,
  subset = FALSE,
  id = FALSE,
  rid = FALSE,
  pa = FALSE,
  minht = NULL,
  maxht = NULL,
  outlier = NULL,
  ignoreoverlap = FALSE,
  strata = NULL,
  intstrata = NULL,
  kde = NULL,
  rgb = NULL,
  use64bit = TRUE,
  runCmd = TRUE,
  saveCmd = TRUE,
  cmdFile = NULL,
  cmdClear = FALSE,
  echoCmd = FALSE,
  comment = NULL
)

Arguments

inputspecifier

character (required): LIDAR data file template, name of text file containing a list of file names (must have .txt extension), or a catalog file.

outputfile

character (required): Name for output file to contain cloud metrics (usually .csv extension). If the folder for the output file does not exist, it will be created when the function is called even when saving commands to a batch file.

quiet

boolean: Suppress all output during the run.

verbose

boolean: Display all status information during the run.

version

boolean: Report version information and exit with no processing.

newlog

boolean: Erase the existing log file and start a new log

log

character: Use the name specified for the log file.

locale

boolean: Adjust program logic to input and output locale-specific numeric formats (e.g. use a comma for the decimal separator).

nolaszipdll

boolean: Suppress the use of the LASzip dll (c) Martin Isenburg... removes support for compressed LAS (LAZ) files. This option is only useful for programs that read or write point files.

skipfilecheck

boolean: Skip logic that checks for valid point files and removes those that are invalid prior to the start of point processing. This option is designed to overcome some limitations with windows and wildcard processing. This option is only useful for programs that read point data.

above

numeric: Compute proportion of first returns above # (canopy cover). Also compute the proportion of all returns above # and the (number of returns above #) / (total number of 1st returns). The same metrics are also computed using the mean and mode point elevation (or height) values. Starting with version 2.0 of CloudMetrics, the /relcover and /alldensity options were removed. All cover metrics are computed when the /above:# switch is used.

new

boolean: Start new output file...delete existing output file.

firstinpulse

boolean: Use only the first return for the pulse to compute metrics.

firstreturn

boolean: Use only first returns to compute metrics.

first

boolean: Use only first returns to compute metrics (same as firstreturn).

highpoint

boolean: Produce a limited set of metrics ([ID],#pts,highX,highY,highZ).

subset

boolean: Produce a limited set of metrics([ID],#pts,Mean ht,Std dev ht, 75th percentile,cover)...must be used with /above:#.

id

boolean: Parse an identifier from the beginning of the data file name... output as the first column of data.

rid

boolean: Parse an identifier from the end of the data file name... output as the first column of data.

pa

boolean: Output detailed percentile data used to compute the canopy profile area. Output file name uses the base output name with _percentile appended.

minht

numeric: Use only returns above # (use when data is normalized to ground) Prior to version 2.20 this switch was /htmin. /htmin can still be used but /minht is preferred. The minht is not used when computing metrics related to the /strata and /intstrata options.

maxht

numeric: Use only returns below # (use when data is normalized to ground) to compute metrics. The maxht is not used when computing metrics related to the /strata or /intstrata options.

outlier

character: "low,high": Omit points with elevations below low and above high. When used with data that has been normalized using a ground surface, low and high are interpreted as heights above ground. You should use care when using /outlier:low,high with /minht and /maxht options. If the low value specified with /outlier is above the value specified with /minht, the value for /outlier will override the value specified for /minht. Similarly, if the high value specified with /outlier is less than the value specified for /maxht, the /outlier value will override the value for /maxht.

ignoreoverlap

boolean: Ignore points with the overlap flag set (LAS V1.4+ format).

strata

character: "#,#,#,...": Count returns in various height strata. # gives the upper limit for each strata. Returns are counted if their height is >= the lower limit and < the upper limit. The first strata contains points < the first limit. The last strata contains points >= the last limit. Default strata: 0.15, 1.37, 5, 10, 20, 30.

intstrata

character: "#, #, #,...": Compute metrics using the intensity values in various height strata. Strata for intensity metrics are defined in the same way as the /strata option. Default strata: 0.25, 1.37.

kde

character: "window,mult": Compute the number of modes and minimum and maximum node using a kernal density estimator. Window is the width of a moving average smoothing window in data units and mult is a multiplier for the bandwidth parameter of the KDE. Default window is 2.5 and the multiplier is 1.0.

rgb

character: "color": Compute intensity metrics using the color value from the RGB color for the returns. Valid with LAS version 1.2 and newer data files that contain RGB information for each return (point record types 2 and 3). Valid color values are R, G, or B.

use64bit

boolean: indicates 64-bit version of the program should be used.

runCmd

boolean: indicates command line should be executed.

saveCmd

boolean: indicates command line should be written to a file.

cmdFile

character: contains the name of the file to which commands should be written.

cmdClear

boolean: indicates file for commands should be deleted (cleared) before the command line is written.

echoCmd

boolean: indicates command line should be displayed.

comment

character string containing comment to be written to command file before writing the actual command. Only used when runCmd = FALSE and saveCmd = TRUE. When written, there is always a blank line before the comment line in the command file.

Value

Return value depends on runCmd. if runCmd = TRUE, return value is the (invisible) integer value return from the operating system after running the command. if runCmd = FALSE, return value is the (invisible) command line.

Multiple Commands

LTKFunctions generate a separate command for each item when the required parameters are lists. This is useful when you want to use the same command and options but different input data and output files. However, this works only when the switches and options are the same for all commands (not lists). If you try to use a list of switches and/or options and a list of input files, you will produce commands using all sets of switches and/or options for every input file.

See Also

Other LTKFunctions: CSV2Grid(), CanopyMaxima(), CanopyModel(), Catalog(), ClipDTM(), ClipData(), Cover(), DTMDescribe(), DensityMetrics(), FilterData(), FirstLastReturn(), GridMetrics(), GridSample(), GridSurfaceCreate(), GridSurfaceStats(), GroundFilter(), IntensityImage(), JoinDB(), MergeDTM(), MergeData(), MergeRaster(), RepairGridDTM(), ReturnDensity(), SplitDTM(), SurfaceSample(), SurfaceStats(), TINSurfaceCreate(), ThinData(), TopoMetrics(), TreeSeg(), fusionwrapr-package

Examples

## Not run: 
CloudMetrics("points/*.las", "test.csv", minht = 2.0)

## End(Not run)

bmcgaughey1/fusionwrapr documentation built on Dec. 1, 2024, 7:13 a.m.