Set a single baseline value given input data.
set_baseline.Rd
Set a single baseline value given input data.
Arguments
- x
A vector of observations
- time
A vector of times when the observations occurred
- min_bl_time, max_bl_time
The minum and maximum possible times for baseline measurements.
- summaryfun
What functions should summarize or modify the baseline value(s)?
- ...
Passed to `summaryfun()`
Details
Possible baseline values are selected when:
`x` is not `NA`
`time` is not `NA`
`min_bl_time <= time`
`time <= max_bl_time`
If no value is possible, NA is returned (of the same class as `x`). Within the possible baseline values, the values with the maximum time are selected, and all selected values are summarized with `summaryfun(selected_values, ...)`