Predicts copy number (CN) from Ct (Cq) values from one or more standard curves using inverse prediction.

calib_predict(calib_df, ct_df, ...)

Arguments

calib_df

A data.frame or tibble object containing calibration curve data.

ct_df

A data.frame or tibble object containing Ct values from environmental samples.

...

Placeholder for further arguments that might be needed by future implementations.

Value

A tibble object containing original data in ct_df with back transformed copy number predictions (CN.back) and associated standard errors (CN.back.se).

Details

The calib_df object contains data for at least one qPCR calibration curve usually presented as Cq (Ct) value and corresponding copy number from from a series of serial dilutions. The data.frame must contain the headers Target, Cq and SQ. The Target column must contain unique identifiers for each calibration curve. The Cq column contains the Cq (Ct) values and SQ contains the copy number data. Additional columns will be ignored.

The ct_df data.frame object usually contains qPCR Cq (Ct) values from sample data. The data.frame must contain the headers calib.curve and Ct.value. The calib.curve column must contain at least one unique calibration curve identifier corresponding to those in calib_df. Any identifiers found in ct_df but not in calib_df will be ignored and a warning displayed. The Ct.value column should contain the Cq (Ct) values from environmental samples. Any additional columns in the data.frame will remain unchanged and be included in the returned object.

Non-detections in either the calib_df or ct_df data.frames should be represented as NA.

Copy number is predicted from Cq (Ct) values by fitting a linear model (lm) to data from each calibration curve and then using the inverse.predict function from the chemCal-package package.

Note

Copy number values in calib_df should not be log transformed prior to using this function.

References

Massart, L.M, Vandenginste, B.G.M., Buydens, L.M.C., De Jong, S., Lewi, P.J., Smeyers-Verbeke, J. (1997) Handbook of Chemometrics and Qualimetrics: Part A, p. 200.

Examples

if (FALSE) { my_pred <- calib_predict(calib_df = calib_data, ct_df = field_data) }