TimeInterval {pvldcurve} | R Documentation |
Time Interval
Description
Calculates time intervals (min) between temporally repeated measurements
Usage
TimeInterval(data, sample = "sample", date.and.time = "date.and.time")
Arguments
data |
data frame containing at least a column giving the time (and date) (class POSIXct) of the measurements ordered by sample and chronologically. A column containing the sample IDs is optionally required if several samples were measured. |
sample |
optional name of the column in data containing the sample ID, default: "sample" |
date.and.time |
optional name of the column in data containing the time (and date) as class POSIXct, default: "date.and.time" |
Value
the original data frame extended by a numerical vecor containing the time intervals (min) between the measurements of a sample. The first values of each sample is NA since time intervals are computed from row i and i-1.
Examples
# get example data
df <- leaf_drying_data
# extend df by time interval
df_with_ti <- TimeInterval(df)
[Package pvldcurve version 1.2.6 Index]