lm_q2e_oneshot: Estimation of peptide q2e in a single linear regression with...

View source: R/wls_q2e.R

lm_q2e_oneshotR Documentation

Estimation of peptide q2e in a single linear regression with nested coefficients

Description

Use a single call to "lm" with nested coefficients per spectra and peptide. Effectively it will calculate separate coefficient for each spectra and peptide.

Usage

lm_q2e_oneshot(
  peaks_df,
  intensity = "norm_int",
  weights = NULL,
  intercept = FALSE
)

Arguments

peaks_df

Data.frame with peaks data and theoretical isotopic envelopes

intensity

Term used as the dependent variable. It could be the unscaled intensity or the normalized at the spectra and peptide level

weights

Column of weights in peaks_df

intercept

Logical, whether to fit an intercept or not

Details

WARNING: this cannot handle too large data.frames. I will try to add biglm at some point. Otherwise data can be grouped by.

Value

A data.frame with q2e estimates


ismaRP/MALDIpqi documentation built on July 2, 2024, 8:43 p.m.