align_input: Create an input file for Fortran program align.

View source: R/input_file_utils.R

align_inputR Documentation

Create an input file for Fortran program align.

Description

Program align co-registers two overlapping DTMs. It characterizes the frequency distribution of elevation differences as functions of slope gradient and aspect, uses that to determine slope- and aspect-dependent thresholds for filtering elevation differences in setting up a set of linear equations to solve for the optimal x-y-z shift of one DTM, solves for the x-y-z shift, generates an aligned DTM, and outputs an elevation difference raster. Inputs to program align are read from an ASCII input file using "Keyword: arguments" format, built here.

Usage

align_input(
  refDTM,
  alignDTM,
  refDSM = "nofile",
  alignDSM = "nofile",
  iterations,
  k,
  dampener,
  outDTM,
  tileNx,
  tileNy,
  overlap,
  radius,
  nslope,
  maxSlope,
  nAzimuth,
  outbins,
  outDif,
  outOutlier,
  scratch_dir
)

Arguments

refDTM

Character: The file name (full path) for the input reference DTM.

alignDTM

Character: The file name (full path) for the input

refDSM

Character: The file name (full path) for the input reference surface height raster (optional).

alignDSM

Character: The file name (full path) for the input DSM raster to align (optional)

iterations

Numeric (int): Number of iterations to solve for the shift

k

Numeric (dbl): Number of inter-quartile ranges to use with a Tukey's fence to identify outliers

dampener

Numeric (dbl): Dampener for the shift

outDTM

Character: File name (full path) for the output aligned DTM

tileNx

(int): number of tiles in the x direction

overlap

(dbl): overlap between tiles

radius

(dbl): radius in meters for measuring slope and aspect

nslope

(int): number of gradient bins

maxSlope

(dbl): maximum gradient for binning

nAzimuth

(int): number of azimuth bins

outbins

Character: output csv file of elevation differences binned by slope and aspect

outDif

Character: output elevation difference raster (.flt)

outOutlier

Character: output outlier raster (.flt)

scratch_dir

Charcter: scratch directory

tilesNy

(int): number of tiles in the y direction

Value

There is no explicit return object, but an explicit side effect is writing to disk of the partial input file.


tabrasel/WetlandTools documentation built on June 1, 2025, 8:07 p.m.