SPACox_Null_Model: Fits a NULL model for SPACox

Description Usage Arguments Value Examples

View source: R/Library.r

Description

Fits a null Cox proportional hazards model and then calculates the empirical cumulant generation function (CGF) of the martingale residuals

Usage

1
2
3
4
5
6
7
8
9
SPACox_Null_Model(
  formula,
  data = NULL,
  pIDs = NULL,
  gIDs = NULL,
  range = c(-100, 100),
  length.out = 10000,
  ...
)

Arguments

formula

a formula to be passed to function coxph(). For more details, please refer to package survival.

data

a data.frame in which to interpret the variables named in the formula

pIDs

a character vector of subject IDs. NOTE: its order should be the same as the subjects order in the formula.

gIDs

a character vector of subject IDs. NOTE: its order should be the same as the subjects order of the Geno.mtx (i.e. the input of the function SPACox()).

range

a two-element numeric vector (default: c(-100,100)) to specify the domain of the empirical CGF.

length.out

a positive integer (default: 9999) for empirical CGF. Larger length.out corresponds to longer calculation time and more accurate estimated empirical CGF.

...

Other arguments passed to function coxph(). For more details, please refer to package survival.

Value

an object with a class of "SPACox_NULL_Model".

Examples

1
Please check help(SPACox) for a simulated example.

WenjianBI/SPACox documentation built on March 5, 2021, 7:23 p.m.