The `gLRT`

function conducts four *k*(>=2)-sample tests for interval-censored survival data. Four of them are different nonparametric generalized logrank tests, and the other is a score test under a proportional hazards model. They are two-sided tests. The null hypothesis is that all *k* survival functions of the failure time are identical, and the alternative hypothesis hypothesis is that not all survival functions are the same. This function calls one of functions (`gLRT1`

, `gLRT2`

, `gLRT3`

, `gLRT4`

, `ScoreTest`

) based on the method specified. However, each of these tests can be called individually to perform a test. Note that `gLRT2`

and `gLRT4`

do not allow exact observations. `gLRT4`

only allows *k = 2* and is no longer called `ScoreTest`

as in Zhao (2012).

1 2 3 |

`A` |
an |

`k` |
number of treatments. The default is 2. |

`method` |
a character string specifying the test to be performed: "glrt1", "glrt2", "glrt3", "glrt4", and "score". |

`M` |
number of multiple imputations used in estimating the covariance in function |

`rho` |
non-negative parameter in |

`gamma` |
non-negative parameter in |

`EMstep` |
a boolean variable indicating whether to take an EM step in the iteration when estimating the common distribution function. The default is TRUE. |

`ICMstep` |
a boolean variable indicating whether to take an ICM step in the iteration when estimating the common distribution function. The default is TRUE. |

`tol` |
the maximal |

`maxiter` |
the maximal number of iterations to perform before stopping when estimating a distribution function. The default is 1000. |

`inf` |
value used in data for infinity. The default is Inf. |

For all tests, it is assumed that the censoring interval for each observation takes the form *(L_i, R_i]*. For exact observations, *L_i = R_i*; for left-censored observations, *L_i = 0*; and for right-censored observations, *R_i = inf*, infinity or a large number representing infinity.

Exact observations are not allowed in `gLRT2`

. If no exactly observations exist, `gLRT3`

reduces to `gLRT2`

in terms of chi-square statistic and p-value.

When `method="glrt1"`

is selected, `gLRT1`

is called to perform the test proposed by Zhao and Sun (2004). When `method="glrt2"`

is selected, `gLRT2`

is called to perform the test proposed by Sun, Zhao, and Zhao (2005). When `method="glrt3"`

is selected, `gLRT3`

is called to perform the test proposed by Zhao, Zhao, Sun, and Kim (2008). When `method="score"`

is selected, `ScoreTest`

is called to perform a score test under a proportional hazards model proposed by Finkelstein (1986). For the above methods, the NPMLE of the common distribution function under the null hypothesis is computed by function `ModifiedEMICM`

. When `method="glrt4"`

is selected, `gLRT4`

is called to perform the test proposed by Zhao, Duan, Zhao, and Sun (2013) where `ModifiedEMICM`

is applied to each of the two groups.

The link function used in `gLRT2`

, `gLRT3`

, and `gLRT4`

is *ξ(x) = x log(x) x^ρ (1 - x)^γ. *

The function returns an object containing the following components:

`method` |
test procedure used |

`u` |
the test statistic |

`v` |
the estimated covariance of the test statistic |

`chisq/fstat` |
the chi-square or f (for |

`df` |
the degrees of freedom of the chis-square test or f-test |

`p` |
p-value of the test |

Qiang Zhao and Jianguo Sun

Q. Zhao and J. Sun (2004), "Generalized Log-rank Test for Mixed-Censored Failure Time Data", Statistics in Medicine, 23: 1621-1629.

J. Sun, Q. Zhao, and X. Zhao (2005), "Generalized Log-rank Test for Interval-Censored Data", Scandinavian Journal of Statistics, 32: 45-57.

X. Zhao, Q. Zhao, J. Sun, Q. and J. S. Kim (2008), "Generalized Log-rank Tests for Partly Interval-Censored Failure Time Data", Biometrical Journal, 50 (3): 375-385.

X. Zhao, R. Duan, Q. Zhao, and J. Sun (2013), "A New Class of Generalized Log Rank Tests for Interval-censored Failure Time Data", Computational Statistics and Data Analysis. 60: 123-131.

Finkelstein, DM (1986), "A Proportional Hazards Model for Interval-censored Failure Time Data", Biometrics, 42: 845-854.

Q. Zhao (2012), "gLRT - A New R Package for Analyzing Interval-censored Survival Data", Interval-Censored Time-to-Event Data: Methods and Applications, CRC Press, 377-396.

`gLRT1`

, `gLRT2`

, `gLRT3`

, `gLRT4`

, `ScoreTest`

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | ```
data(cosmesis)
gLRT(cosmesis, method="glrt1", M=20, inf=100)
gLRT(cosmesis, method="glrt2", rho=1, inf=100)
data(diabetes)
gLRT(diabetes, method="glrt3", gamma=1)
gLRT(diabetes, method="score")
data(cmv)
cmvBlood = cmv[,c(2,3,6)]
cmvUrine = cmv[, 4:6]
gLRT(cmvBlood, method="glrt4")
gLRT(cmvUrine, method="glrt4", rho=1, gamma=1)
# 3-sample test
data(cosmesis)
cosmesis[80:94, 3] = 2
gLRT(cosmesis, k=3, method="glrt3", rho=0, gamma=0, inf=100)
``` |

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.