PWD_inference: Weighted Deming Regression - Inference

View source: R/PWD_inference.r

PWD_inferenceR Documentation

Weighted Deming Regression – Inference

Description

This routine fits the regression, uses the jackknife to get its precision, and optionally prints it out. Currently implements Rocke-Lorenzato as the variance profile model.

Usage

PWD_inference(X, Y, lambda=1, MDL=NA, epsilon=1e-8, printem=FALSE)

Arguments

X

the vector of predicate readings,

Y

the vector of test readings,

lambda

optional (default of 1) - the ratio of the X to the Y precision profile.

MDL

optional (default to missing) - medical decision level(s),

epsilon

optional (default of 1.e-8) - convergence tolerance limit,

printem

optional - if TRUE, routine will print out results as a message.

Details

For the linear model relating the predicate and test readings, the standard errors of the estimators \hat{\alpha}, \hat{\beta}, and their covariance are estimated by the jackknife. The estimates of the intercept and slope are output, along with their standard errors and covariance.

These estimates are further used to estimate the predictions at the input MDL.

Value

A list containing the following components:

alpha

the fitted intercept

beta

the fitted slope

cor

the Pearson correlation between X and Y

fity

the vector of predicted Y

mu

the vector of estimated latent true values

resi

the vector of residuals

preresi

the vector of leave-one-out predicted residuals

sigma

the estimate of the Rocke-Lorenzato \sigma

kappa

the estimate of the Rocke-Lorenzato \kappa

like

the -2 log likelihood L

sealpha

the jackknife standard error of alpha

sebeta

the jackknife standard error of beta

covar

the jackknife covariance between alpha and beta

preMDL

the predictions at the MDL(s)

preMDLl

the lower confidence limit(s) of preMDL

preMDLu

the upper confidence limit(s) of preMDL

Author(s)

Douglas M. Hawkins, Jessica J. Kraker krakerjj@uwec.edu

References

Hawkins DM and Kraker JJ. Precision Profile Weighted Deming Regression for Methods Comparison, on Arxiv (2025) doi:10.48550/arXiv.2508.02888

Efron, B (1982). The jackknife, the bootstrap and other resampling plans. Society for Industrial and Applied Mathematics.

Examples

# library
library(ppwdeming)

# parameter specifications
sigma <- 1
kappa <- 0.08
alpha <- 1
beta  <- 1.1
true  <- 8*10^((0:99)/99)
truey <- alpha+beta*true
# simulate single sample - set seed for reproducibility
set.seed(1039)
# specifications for predicate method
X     <- sigma*rnorm(100)+true *(1+kappa*rnorm(100))
# specifications for test method
Y     <- sigma*rnorm(100)+truey*(1+kappa*rnorm(100))

# fit with RL precision profile to estimate parameters and variability
RL_inf <- PWD_inference(X,Y,MDL=12,printem=TRUE)


ppwdeming documentation built on Sept. 9, 2025, 5:37 p.m.