Skip to contents

Corrects flights data to transform IR-measured temperatures into operative temperatures

Usage

correct_flights_data(
  flights_data,
  otm_splines,
  time_correction,
  time_correction_metric,
  flight_specific_correction
)

Arguments

flights_data

A data frame of flights data obtained through the rnp_flights_data function.

otm_splines

A nested tibble obtained using the gen_otm_splines function.

time_correction

A logical value (TRUE or FALSE) indicating whether first correction step should be applied. If set to TRUE, the function will add the mean, median or mode (based on time_correction_metric, see below) bias between all surface and operative temperatures in tiles where OTMs were present to all surface temperature measurements within a flight. The goal of applying a time correction is to account for day and time-specific systematic biases between operative and surface temperatures which may be a by product of the inherent nature of thermal imaging (e.g., measurements being influenced by light conditions, sensor calibration. etc.). time_correction = TRUE if flight_specific_correction = FALSE is recommended.

time_correction_metric

A character string indicating the metric to be used to perform the time correction. The metric can be either "mean", "median" or "mode".For most cases, "mean" is recommended but "median" could be used if outliers are detected. To evaluate the best method, use the function eval_flights_correction also included in throne.

flight_specific_correction

A logical value (TRUE or FALSE) indicating whether the second correction step should be applied to all flights or each flight specifically. If set to TRUE the second correction step will also incorporate the effects of day of the year and minute of day into the linear model from which the correction will be performed.

Value

A processed flights_data

tibble where IR-measured surface temperatures (surf_temp) has been corrected to operative temperatures (op_temp).