Using spline fits of observed retention time deviations from "average samples" update the retention time of a data.frame

update_sample_rt(x, rt_var, sample_var, rt_deviation_gams)

Arguments

x

an input data.frame (or data_frame)

rt_var

the column name of an rt variable to be transformed into a new variable "rt_update"

sample_var

a sample variable which matches the sample's retention time deviation gam

rt_deviation_gams

a tibble of sample-specific retention time update GAMs.