flatten_data {Xcertainty} | R Documentation |
Reformat photogrammetric data for model-based analysis
Description
For internal use only. Not intended to be called directly by users.
Usage
flatten_data(
data = NULL,
priors,
pixel_counts = data$pixel_counts,
training_objects = data$training_objects,
image_info = data$image_info,
prediction_objects = data$prediction_objects
)
Arguments
data |
A |
priors |
|
pixel_counts |
|
training_objects |
|
image_info |
|
prediction_objects |
|
Details
Assemble data.frame
objects into a format that can be analyzed using
numerical methods. This function is analagous to stats::model.matrix
,
which generates design matrices for models that are specified via formulas.
Examples
# load example wide-format data
data("calibration")
data("whales")
# parse calibration study
calibration_data = parse_observations(
x = calibration,
subject_col = 'CO.ID',
meas_col = 'Lpix',
tlen_col = 'CO.L',
image_col = 'image',
barometer_col = 'Baro_Alt',
laser_col = 'Laser_Alt',
flen_col = 'Focal_Length',
iwidth_col = 'Iw',
swidth_col = 'Sw',
uas_col = 'uas'
)
# parse field study
whale_data = parse_observations(
x = whales,
subject_col = 'whale_ID',
meas_col = 'TL.pix',
image_col = 'Image',
barometer_col = 'AltitudeBarometer',
laser_col = 'AltitudeLaser',
flen_col = 'FocalLength',
iwidth_col = 'ImageWidth',
swidth_col = 'SensorWidth',
uas_col = 'UAS',
timepoint_col = 'year'
)
# combine parsed calibration and observation (whale) data
combined_data = combine_observations(calibration_data, whale_data)