GPC_cpp: C++ function performing the pairwise comparison over several...

View source: R/RcppExports.R

GPC_cppR Documentation

C++ function performing the pairwise comparison over several endpoints.

Description

GPC_cpp call for each endpoint and each strata the pairwise comparison function suited to the type of endpoint and store the results.

Usage

GPC_cpp(
  endpoint,
  status,
  indexC,
  posC,
  indexT,
  posT,
  threshold,
  restriction,
  weightEndpoint,
  weightObs,
  method,
  pool,
  op,
  D,
  D_UTTE,
  n_strata,
  nUTTE_analyzedPeron_M1,
  index_endpoint,
  index_status,
  index_UTTE,
  list_survTimeC,
  list_survTimeT,
  list_survJumpC,
  list_survJumpT,
  list_lastSurv,
  p_C,
  p_T,
  iid_survJumpC,
  iid_survJumpT,
  zeroPlus,
  correctionUninf,
  hierarchical,
  hprojection,
  neutralAsUninf,
  addHalfNeutral,
  keepScore,
  precompute,
  returnIID,
  debug
)

GPC2_cpp(
  endpoint,
  status,
  indexC,
  posC,
  indexT,
  posT,
  threshold,
  restriction,
  weightEndpoint,
  weightObs,
  method,
  pool,
  op,
  D,
  D_UTTE,
  n_strata,
  nUTTE_analyzedPeron_M1,
  index_endpoint,
  index_status,
  index_UTTE,
  list_survTimeC,
  list_survTimeT,
  list_survJumpC,
  list_survJumpT,
  list_lastSurv,
  p_C,
  p_T,
  iid_survJumpC,
  iid_survJumpT,
  zeroPlus,
  correctionUninf,
  hierarchical,
  hprojection,
  neutralAsUninf,
  addHalfNeutral,
  keepScore,
  precompute,
  returnIID,
  debug
)

Arguments

endpoint

A matrix containing the values of each endpoint (in columns) for each observation (in rows).

status

A matrix containing the values of the status variables relative to each endpoint (in columns) for each observation (in rows).

indexC

A list containing, for each strata, which rows of the endpoint and status matrices corresponds to the control observations. Not unique when bootstraping.

posC

A list containing, for each strata, the unique identifier of each control observations.

indexT

A list containing, for each strata, which rows of the endpoint and status matrices corresponds to the treatment observations. Not unique when bootstraping.

posT

A list containing, for each strata, the unique identifier of each treatment observations.

threshold

Store the thresholds associated to each endpoint. Must have length D. The threshold is ignored for binary endpoints.

restriction

Store the restriction time associated to each endpoint. Must have length D.

weightEndpoint

Store the weight associated to each endpoint. Must have length D.

weightObs

A vector containing the weight associated to each observation.

method

The index of the method used to score the pairs. Must have length D. 1 for binary/continuous, 2 for Gaussian, 3/4 for Gehan (left or right-censoring), and 5/6 for Peron (right-censoring survival or competing risks).

pool

The index of the method used to pool results across strata. Can be 0 (weight inversely proportional to the sample size), 1 (Mantel Haenszel weights), 2 (equal weights), 3 (precision weights)

op

The index of the operator used to score the pairs. Must have length D. 1 for larger is beter, -1 for smaller is better.

D

The number of endpoints.

D_UTTE

The number of distinct time to event endpoints.

n_strata

The number of strata.

nUTTE_analyzedPeron_M1

The number of unique time-to-event endpoints that have been analyzed the Peron scoring rule before the current endpoint. Must have length D.

index_endpoint

The position of the endpoint at each priority in the argument endpoint. Must have length D.

index_status

The position of the status at each priority in the argument status. Must have length D.

index_UTTE

The position, among all the unique tte endpoints, of the TTE endpoints. Equals -1 for non tte endpoints. Must have length n_TTE.

list_survTimeC

A list of matrix containing the survival estimates (-threshold, 0, +threshold ...) for each event of the control group (in rows).

list_survTimeT

A list of matrix containing the survival estimates (-threshold, 0, +threshold ...) for each event of the treatment group (in rows).

list_survJumpC

A list of matrix containing the survival estimates and survival jumps when the survival for the control arm jumps.

list_survJumpT

A list of matrix containing the survival estimates and survival jumps when the survival for the treatment arm jumps.

list_lastSurv

A list of matrix containing the last survival estimate in each strata (rows) and treatment group (columns).

p_C

Number of nuisance parameter in the survival model for the control group, for each endpoint and strata

p_T

Number of nuisance parameter in the survival model for the treatment group, for each endpoint and strata

iid_survJumpC

A list of matrix containing the iid of the survival estimates in the control group.

iid_survJumpT

A list of matrix containing the iid of the survival estimates in the treatment group.

zeroPlus

Value under which doubles are considered 0?

correctionUninf

Should the uninformative weight be re-distributed to favorable and unfavorable?

hierarchical

Should only the uninformative pairs be analyzed at the lower priority endpoints (hierarchical GPC)? Otherwise all pairs will be compaired for all endpoint (full GPC).

hprojection

Order of the H-projection used to compute the variance.

neutralAsUninf

Should paired classified as neutral be re-analyzed using endpoints of lower priority?

addHalfNeutral

Should half of the neutral score be added to the favorable and unfavorable scores?

keepScore

Should the result of each pairwise comparison be kept?

precompute

Have the integrals relative to the survival be already computed and stored in list_survTimeC/list_survTimeT and list_survJumpC/list_survJumpT (derivatives)

returnIID

Should the iid be computed? Second element: is there any nuisance parameter?

debug

Print messages tracing the execution of the function to help debugging. The amount of messages increase with the value of debug (0-5).

Details

GPC_cpp implements GPC looping first over endpoints and then over pairs. To handle multiple endpoints, it stores some of the results which can be memory demanding when considering large sample - especially when computing the iid decomposition. GPC2_cpp implements GPC looping first over pairs and then over endpoints. It has rather minimal memory requirement but does not handle correction for uninformative pairs.

Author(s)

Brice Ozenne


BuyseTest documentation built on March 31, 2023, 6:55 p.m.