Type: Package
Title: Proximal Weighting Estimation for Dependent Left Truncation
Version: 0.1.0
Description: Implements proximal weighting estimators for the expectation of an arbitrarily transformed event time under dependent left truncation, with optional inverse probability of censoring weighting to handle right censoring. The methods leverage proxy variables to handle dependent left truncation in settings where dependence-inducing factors are not fully observed.
License: GPL-3
Encoding: UTF-8
Depends: R (≥ 4.1.0)
Imports: Rcpp, survival
LinkingTo: Rcpp, RcppArmadillo
Suggests: testthat (≥ 3.0.0)
Config/testthat/edition: 3
URL: https://github.com/wangyuyao98/truncProxy_weighting, https://arxiv.org/pdf/2512.21283
BugReports: https://github.com/wangyuyao98/truncProxy_weighting/issues
RoxygenNote: 7.3.2
NeedsCompilation: yes
Packaged: 2026-04-19 18:10:14 UTC; yuyaowang
Author: Yuyao Wang [aut, cre], Andrew Ying [aut], Ronghui Xu [aut]
Maintainer: Yuyao Wang <yuw079@ucsd.edu>
Repository: CRAN
Date/Publication: 2026-04-21 20:40:09 UTC

truncProxy: Proximal Weighting Estimation for Dependent Left Truncation

Description

Implements proximal weighting estimators for the expectation of an arbitrarily transformed event time under dependent left truncation, with optional inverse probability of censoring weighting to handle right censoring. The methods leverage proxy variables to handle dependent left truncation in settings where dependence-inducing factors are not fully observed.

Author(s)

Maintainer: Yuyao Wang yuw079@ucsd.edu

Authors:

See Also

Useful links:


IPCW-Adjusted Proximal Weighting Estimation under Dependent Left Truncation and Random Right Censoring

Description

Computes the IPCW-adjusted proximal weighting estimator for the expectation of an arbitrarily transformed event time under dependent left truncation and random right censoring.

Usage

PQB_IPCW_estimator(
  nu,
  t0,
  dat,
  time.name,
  Q.name,
  event.name = NULL,
  W1.name,
  W2.name,
  Z.name,
  weights = rep(1, nrow(dat)),
  trim.min = 1e-07,
  trim.max = 1e+07,
  IPCW_time_varying = FALSE,
  trim.IPCW = 1e-07
)

Arguments

nu

A user-supplied transformation of the event time. For example, function(t) as.numeric(t > tau) results in estimating a survival probability beyond time tau.

t0

A cutoff such that nu(t) = nu(min(t, t0)). For example, for survival probability at time tau, one can set t0 = tau.

dat

A data frame containing the observed data.

time.name

Name of the observed event or censoring time variable.

Q.name

Name of the left truncation time variable.

event.name

Name of the event indicator variable. Set to NULL when there is no right censoring.

W1.name

Name of the truncation proxies.

W2.name

Name of the event time proxies.

Z.name

Name of the measured covariates that are directly associated with both the event time and the truncation time.

weights

Optional nonnegative case weights. Defaults to equal weights.

trim.min

Lower bound used to stabilize the estimated bridge weights.

trim.max

Upper bound used to stabilize the estimated bridge weights.

IPCW_time_varying

Logical; if TRUE, use time-varying IPCW weights in the bridge estimation step.

trim.IPCW

Lower bound used to stabilize the denominators of IPCW weights.

Value

A numeric scalar containing the IPCW-adjusted proximal weighting estimator.


Proximal Weighting Estimation Under Dependent Left Truncation

Description

Computes the proximal weighting estimator for the expectation of an arbitrarily transformed event time under dependent left truncation.

Usage

PQB_estimator(
  nu,
  dat,
  time.name,
  Q.name,
  W1.name,
  W2.name,
  Z.name,
  weights = rep(1, nrow(dat)),
  trim.min = 1e-07,
  trim.max = 1e+07
)

Arguments

nu

A user-supplied transformation of the event time. For example, function(t) as.numeric(t > tau) results in estimating a survival probability beyond time tau.

dat

A data frame containing the observed data.

time.name

Name of the event time variable.

Q.name

Name of the left truncation time variable.

W1.name

Name of the truncation proxies.

W2.name

Name of the event time proxies.

Z.name

Name of the measured covariates that are directly associated with both the event time and the truncation time.

weights

Optional nonnegative case weights. Defaults to equal weights.

trim.min

Lower bound used to stabilize the estimated bridge weights.

trim.max

Upper bound used to stabilize the estimated bridge weights.

Value

A numeric scalar containing the proximal weighting estimator.