Title: | Copula Markov Model with Dependent Censoring |
---|---|
Description: | Perform likelihood estimation and corresponding analysis under the copula-based Markov chain model for serially dependent event times with a dependent terminal event. Available are statistical methods in Huang, Wang and Emura (2020, JJSD accepted). |
Authors: | Xin-Wei Huang, Takeshi Emura |
Maintainer: | Xin-Wei Huang <[email protected]> |
License: | GPL-3 |
Version: | 1.0.0 |
Built: | 2025-02-18 03:55:13 UTC |
Source: | https://github.com/cran/Copula.Markov.survival |
The data generation process is based on the Clayton copula C_theta for serial dependence and the Clayton copula tilde(C)_alpha for dependent censoring with the marginal distributions Weib(scale1, shape1) and Weib(scale2, shape2). Censoring percentage can be controlled by constant b. This function is used when doing parametric bootstrap. The guide for using this function shall be explained by Huang (2019), and Huang, Wang and Emura (2020).
ClaytonClayton.Weibull.data(N, scale1, shape1, theta, scale2, shape2, alpha, b, l)
ClaytonClayton.Weibull.data(N, scale1, shape1, theta, scale2, shape2, alpha, b, l)
N |
sample size |
scale1 |
scale parameter for Weib(scale1, shape1), scale1 > 0 |
shape1 |
shape parameter for Weib(scale1, shape1), shape1 > 0 |
theta |
copula parameter for C_theta, theta > 0 |
scale2 |
scale parameter for Weib(scale2, shape2), scale2 > 0 |
shape2 |
shape parameter for Weib(scale2, shape2), shape2 > 0 |
alpha |
copula parameter for tilde(C)_alpha, alpha > 0 |
b |
parameter of Unif(0, b) for controlling censoring percentage |
l |
length for data generation (default = 300) |
A list with the following elements:
Subject |
a vector for numbers of subject |
T_ij |
a vector for event times |
delta_ij |
a vector for event indicator (=1 if recurrent; =0 if censoring) |
T_i_star |
a vector for death times |
delta_i_star |
a vector for death indicator (=1 if death; =0 if censoring) |
Xinwei Huang
Huang XW, Wang W, Emura T (2020) A copula-based Markov chain model for serially dependent event times with a dependent terminal event. Japanese Journal of Statistics & Data Science. Accepted.
Y = ClaytonClayton.Weibull.data(N = 100, scale1 = 1, shape1 =0.5, theta = 2, scale2 = 0.45, shape2 = 0.5, alpha = 2, b = 10, l = 300)
Y = ClaytonClayton.Weibull.data(N = 100, scale1 = 1, shape1 =0.5, theta = 2, scale2 = 0.45, shape2 = 0.5, alpha = 2, b = 10, l = 300)
Perform two-stage estimation based on the Clayton copula C_theta for serial dependence and the Clayton copula tilde(C)_alpha for dependent censoring with the marginal distributions Weib(scale1, shape1) and Weib(scale2, shape2). The jackknife method estimates the asymptotic covariance matrix. Parametric bootstrap is applied while doing Kolmogorov-Smirnov tests and Cramer-von Mises test. The guide for using this function shall be explained by Huang (2019), and Huang, Wang and Emura (2020).
ClaytonClayton.Weibull.MLE(subject, t.event, event, t.death, death, stageI, Weibull.plot, jackknife, plot, GOF, GOF.plot, rep.GOF, digit)
ClaytonClayton.Weibull.MLE(subject, t.event, event, t.death, death, stageI, Weibull.plot, jackknife, plot, GOF, GOF.plot, rep.GOF, digit)
subject |
a vector for numbers of subject |
t.event |
a vector for event times |
event |
a vector for event indicator (=1 if recurrent; =0 if censoring) |
t.death |
a vector for death times |
death |
a vector for death indicator (=1 if death; =0 if censoring) |
stageI |
an option to select MLE or LSE method for the 1st-stage optimization |
Weibull.plot |
if TRUE, show the Weibull probability plot |
jackknife |
if TRUE, the jackknife method is used for estimate covariance matrix (default = TRUE) |
plot |
if TRUE, the plots for marginal distributions are shown (default = FALSE) |
GOF |
if TRUE, show the p-values for KS-test and CvM-test |
GOF.plot |
if TRUE, show the model diagnostic plot |
rep.GOF |
repetition number of parametric bootstrap |
digit |
accurate to some decimal places |
When jackknife=FALSE, the corresponding standard error and confidence interval values are shown as NA.
A list with the following elements:
Sample_size |
Sample size N |
Case |
Count for event occurences |
scale1 |
Scale parameter for Weib(scale1, shape1) |
shape1 |
Shape parameter for Weib(scale1, shape1) |
scale2 |
Scale parameter for Weib(scale2, shape2) |
shape2 |
Shape parameter for Weib(scale2, shape2) |
theta |
Copula parameter for the Clayton copula C_theta |
alpha |
Copula parameter for the Clayton copula tilde(C)_alpha |
COV |
Asymptotic covariance estimated by the jackknife method |
KS |
Kolmogorov-Smirnov test statistics |
p.KS |
P-values for Kolmogorov-Smirnov tests |
CM |
Cramer-von Mises test statistics |
p.CM |
P-values for Cramer-von Mises tests |
Convergence |
Convergence results for each stage |
Jackknife_error |
Count for error in jackknife repititions |
Log_likelihood |
Log-likelihood values |
Xinwei Huang
Huang XW, Wang W, Emura T (2020) A copula-based Markov chain model for serially dependent event times with a dependent terminal event. Japanese Journal of Statistics & Data Science. Accepted.
data = ClaytonClayton.Weibull.data(N = 30, scale1 = 1, shape1 =0.5, theta = 2, scale2 = 0.45, shape2 = 0.5, alpha = 2, b = 10, l = 300) ClaytonClayton.Weibull.MLE(subject = data$Subject, t.event = data$T_ij, event = data$delta_ij, t.death = data$T_i_star, death = data$delta_i_star, jackknife= TRUE, plot = TRUE)
data = ClaytonClayton.Weibull.data(N = 30, scale1 = 1, shape1 =0.5, theta = 2, scale2 = 0.45, shape2 = 0.5, alpha = 2, b = 10, l = 300) ClaytonClayton.Weibull.MLE(subject = data$Subject, t.event = data$T_ij, event = data$delta_ij, t.death = data$T_i_star, death = data$delta_i_star, jackknife= TRUE, plot = TRUE)
The data generation process is based on the Clayton copula C_theta for serial dependence and the Frank copula tilde(C)_alpha for dependent censoring with the marginal distributions Weib(scale1, shape1) and Weib(scale2, shape2). Censoring percentage can be controlled by constant b. This function is used when doing parametric bootstrap. The guide for using this function shall be explained by Huang (2019), and Huang, Wang and Emura (2020).
ClaytonFrank.Weibull.data(N, scale1, shape1, theta, scale2, shape2, alpha, b, l)
ClaytonFrank.Weibull.data(N, scale1, shape1, theta, scale2, shape2, alpha, b, l)
N |
sample size |
scale1 |
scale parameter for Weib(scale1, shape1), scale1 > 0 |
shape1 |
shape parameter for Weib(scale1, shape1), shape1 > 0 |
theta |
copula parameter for C_theta, theta > 0 |
scale2 |
scale parameter for Weib(scale2, shape2), scale2 > 0 |
shape2 |
shape parameter for Weib(scale2, shape2), shape2 > 0 |
alpha |
copula parameter for tilde(C)_alpha, alpha |
b |
parameter of Unif(0, b) for controlling censoring percentage |
l |
length for data generation (default = 300) |
A list with the following elements:
Subject |
a vector for numbers of subject |
T_ij |
a vector for event times |
delta_ij |
a vector for event indicator (=1 if recurrent; =0 if censoring) |
T_i_star |
a vector for death times |
delta_i_star |
a vector for death indicator (=1 if death; =0 if censoring) |
Xinwei Huang
Huang XW, Wang W, Emura T (2020) A copula-based Markov chain model for serially dependent event times with a dependent terminal event. Japanese Journal of Statistics & Data Science. Accepted.
Y = ClaytonFrank.Weibull.data(N = 100, scale1 = 1, shape1 =0.5, theta = 2, scale2 = 0.45, shape2 = 0.5, alpha = 2, b = 10, l = 300)
Y = ClaytonFrank.Weibull.data(N = 100, scale1 = 1, shape1 =0.5, theta = 2, scale2 = 0.45, shape2 = 0.5, alpha = 2, b = 10, l = 300)
Perform two-stage estimation based on the Clayton copula C_theta for serial dependence and the Frank copula tilde(C)_alpha for dependent censoring with the marginal distributions Weib(scale1, shape1) and Weib(scale2, shape2). The jackknife method estimates the asymptotic covariance matrix. Parametric bootstrap is applied while doing Kolmogorov-Smirnov tests and Cramer-von Mises test. The guide for using this function shall be explained by Huang (2019) and Huang, Wang and Emura (2020).
ClaytonFrank.Weibull.MLE(subject, t.event, event, t.death, death, stageI, Weibull.plot, jackknife, plot, GOF, GOF.plot, rep.GOF, digit)
ClaytonFrank.Weibull.MLE(subject, t.event, event, t.death, death, stageI, Weibull.plot, jackknife, plot, GOF, GOF.plot, rep.GOF, digit)
subject |
a vector for numbers of subject |
t.event |
a vector for event times |
event |
a vector for event indicator (=1 if recurrent; =0 if censoring) |
t.death |
a vector for death times |
death |
a vector for death indicator (=1 if death; =0 if censoring) |
stageI |
an option to select MLE or LSE method for the 1st-stage optimization |
Weibull.plot |
if TRUE, show the Weibull probability plot |
jackknife |
if TRUE, the jackknife method is used for estimate covariance matrix (default = TRUE) |
plot |
if TRUE, the plots for marginal distributions are shown (default = FALSE) |
GOF |
if TRUE, show the p-values for KS-test and CvM-test |
GOF.plot |
if TRUE, show the model diagnostic plot |
rep.GOF |
repetition number of parametric bootstrap |
digit |
accurate to some decimal places |
When jackknife=FALSE, the corresponding standard error and confidence interval values are shown as NA.
A list with the following elements:
Sample_size |
Sample size N |
Case |
Count for event occurences |
scale1 |
Scale parameter for Weib(scale1, shape1) |
shape1 |
Shape parameter for Weib(scale1, shape1) |
scale2 |
Scale parameter for Weib(scale2, shape2) |
shape2 |
Shape parameter for Weib(scale2, shape2) |
theta |
Copula parameter for the Clayton copula C_theta |
alpha |
Copula parameter for the Frank copula tilde(C)_alpha |
COV |
Asymptotic covariance estimated by the jackknife method |
KS |
Kolmogorov-Smirnov test statistics |
p.KS |
P-values for Kolmogorov-Smirnov tests |
CM |
Cramer-von Mises test statistics |
p.CM |
P-values for Cramer-von Mises tests |
Convergence |
Convergence results for each stage |
Jackknife_error |
Count for error in jackknife repititions |
Log_likelihood |
Log-likelihood values |
Xinwei Huang
Huang XW, Wang W, Emura T (2020) A copula-based Markov chain model for serially dependent event times with a dependent terminal event. Japanese Journal of Statistics & Data Science. Accepted.
data = ClaytonFrank.Weibull.data(N = 30, scale1 = 1, shape1 =0.5, theta = 2, scale2 = 0.45, shape2 = 0.5, alpha = 2, b = 10, l = 300) ClaytonFrank.Weibull.MLE(subject = data$Subject, t.event = data$T_ij, event = data$delta_ij, t.death = data$T_i_star, death = data$delta_i_star, jackknife= TRUE, plot = TRUE)
data = ClaytonFrank.Weibull.data(N = 30, scale1 = 1, shape1 =0.5, theta = 2, scale2 = 0.45, shape2 = 0.5, alpha = 2, b = 10, l = 300) ClaytonFrank.Weibull.MLE(subject = data$Subject, t.event = data$T_ij, event = data$delta_ij, t.death = data$T_i_star, death = data$delta_i_star, jackknife= TRUE, plot = TRUE)
Perform likelihood estimation and corresponding analysis under the copula-based Markov chain model for serially dependent event times with a dependent terminal event. A two stage estimation method is applied for estimating model parameters. Two copula functions are used for measuring dependence. One is used for modeling serial dependence in recurrent event times. The other one is for modeling dependent censoring. The baseline hazard functions are modeled by the Weibull distributions. See Huang (2019) <https://etd.lib.nctu.edu.tw/cgi-bin/gs32/ncugsweb.cgi?o=dncucdr&s=id=
Xinwei Huang [email protected]
Huang, X.-W. (2019). Likelihood-based inference for copula-based Markov chain models for continuous, discrete, and survival data. NCU library.
The data generation process is based on the Frank copula C_theta for serial dependence and the Clayton copula tilde(C)_alpha for dependent censoring with the marginal distributions Weib(scale1, shape1) and Weib(scale2, shape2). Censoring percentage can be controlled by constant c. This function is used when doing parametric bootstrap. The guide for using this function shall be explained by Huang (2019), and Huang, Wang and Emura (2020).
FrankClayton.Weibull.data(N, scale1, shape1, theta, scale2, shape2, alpha, b, l)
FrankClayton.Weibull.data(N, scale1, shape1, theta, scale2, shape2, alpha, b, l)
N |
sample size |
scale1 |
scale parameter for Weib(scale1, shape1), scale1 > 0 |
shape1 |
shape parameter for Weib(scale1, shape1), shape1 > 0 |
theta |
copula parameter for C_theta, theta |
scale2 |
scale parameter for Weib(scale2, shape2), scale2 > 0 |
shape2 |
shape parameter for Weib(scale2, shape2), shape2 > 0 |
alpha |
copula parameter for tilde(C)_alpha, alpha > 0 |
b |
parameter of Unif(0, b) for controlling censoring percentage |
l |
length for data generation (default = 300) |
A list with the following elements:
Subject |
a vector for numbers of subject |
T_ij |
a vector for event times |
delta_ij |
a vector for event indicator (=1 if recurrent; =0 if censoring) |
T_i_star |
a vector for death times |
delta_i_star |
a vector for death indicator (=1 if death; =0 if censoring) |
Xinwei Huang
Huang XW, Wang W, Emura T (2020) A copula-based Markov chain model for serially dependent event times with a dependent terminal event. Japanese Journal of Statistics & Data Science. Accepted.
Y = FrankClayton.Weibull.data(N = 100, scale1 = 1, shape1 =0.5, theta = 2, scale2 = 0.45, shape2 = 0.5, alpha = 2, b = 10, l = 300)
Y = FrankClayton.Weibull.data(N = 100, scale1 = 1, shape1 =0.5, theta = 2, scale2 = 0.45, shape2 = 0.5, alpha = 2, b = 10, l = 300)
Perform two-stage estimation based on the Frank copula C_theta for serial dependence and the Clayton copula tilde(C)_alpha for dependent censoring with the marginal distributions Weib(scale1, shape1) and Weib(scale2, shape2). The jackknife method estimates the asymptotic covariance matrix. Parametric bootstrap is applied while doing Kolmogorov-Smirnov tests and Cramer-von Mises test. The guide for using this function shall be explained by Huang (2019), and Huang, Wang and Emura (2020).
FrankClayton.Weibull.MLE(subject, t.event, event, t.death, death, stageI, Weibull.plot, jackknife, plot, GOF, GOF.plot, rep.GOF, digit)
FrankClayton.Weibull.MLE(subject, t.event, event, t.death, death, stageI, Weibull.plot, jackknife, plot, GOF, GOF.plot, rep.GOF, digit)
subject |
a vector for numbers of subject |
t.event |
a vector for event times |
event |
a vector for event indicator (=1 if recurrent; =0 if censoring) |
t.death |
a vector for death times |
death |
a vector for death indicator (=1 if death; =0 if censoring) |
stageI |
an option to select MLE or LSE method for the 1st-stage optimization |
Weibull.plot |
if TRUE, show the Weibull probability plot |
jackknife |
if TRUE, the jackknife method is used for estimate covariance matrix (default = TRUE) |
plot |
if TRUE, the plots for marginal distributions are shown (default = FALSE) |
GOF |
if TRUE, show the p-values for KS-test and CvM-test |
GOF.plot |
if TRUE, show the model diagnostic plot |
rep.GOF |
repetition number of parametric bootstrap |
digit |
accurate to some decimal places |
When jackknife=FALSE, the corresponding standard error and confidence interval values are shown as NA.
A list with the following elements:
Sample_size |
Sample size N |
Case |
Count for event occurences |
scale1 |
Scale parameter for Weib(scale1, shape1) |
shape1 |
Shape parameter for Weib(scale1, shape1) |
scale2 |
Scale parameter for Weib(scale2, shape2) |
shape2 |
Shape parameter for Weib(scale2, shape2) |
theta |
Copula parameter for the Frank copula C_theta |
alpha |
Copula parameter for the Clayton copula tilde(C)_alpha |
COV |
Asymptotic covariance estimated by the jackknife method |
KS |
Kolmogorov-Smirnov test statistics |
p.KS |
P-values for Kolmogorov-Smirnov tests |
CM |
Cramer-von Mises test statistics |
p.CM |
P-values for Cramer-von Mises tests |
Convergence |
Convergence results for each stage |
Jackknife_error |
Count for error in jackknife repititions |
Log_likelihood |
Log-likelihood values |
Xinwei Huang
data = FrankClayton.Weibull.data(N = 30, scale1 = 1, shape1 =0.5, theta = 2, scale2 = 0.45, shape2 = 0.5, alpha = 2, b = 10, l = 300) FrankClayton.Weibull.MLE(subject = data$Subject, t.event = data$T_ij, event = data$delta_ij, t.death = data$T_i_star, death = data$delta_i_star, jackknife= TRUE, plot = TRUE)
data = FrankClayton.Weibull.data(N = 30, scale1 = 1, shape1 =0.5, theta = 2, scale2 = 0.45, shape2 = 0.5, alpha = 2, b = 10, l = 300) FrankClayton.Weibull.MLE(subject = data$Subject, t.event = data$T_ij, event = data$delta_ij, t.death = data$T_i_star, death = data$delta_i_star, jackknife= TRUE, plot = TRUE)
The data generation process is based on the Frank copula C_theta for serial dependence and the Frank copula tilde(C)_alpha for dependent censoring with the marginal distributions Weib(scale1, shape1) and Weib(scale2, shape2). Censoring percentage can be controlled by constant c. This function is used when doing parametric bootstrap. The guide for using this function shall be explained by Huang (2019), and Huang, Wang and Emura (2020).
FrankFrank.Weibull.data(N, scale1, shape1, theta, scale2, shape2, alpha, b, l)
FrankFrank.Weibull.data(N, scale1, shape1, theta, scale2, shape2, alpha, b, l)
N |
sample size |
scale1 |
scale parameter for Weib(scale1, shape1), scale1 > 0 |
shape1 |
shape parameter for Weib(scale1, shape1), shape1 > 0 |
theta |
copula parameter for C_theta, theta |
scale2 |
scale parameter for Weib(scale2, shape2), scale2 > 0 |
shape2 |
shape parameter for Weib(scale2, shape2), shape2 > 0 |
alpha |
copula parameter for tilde(C)_alpha, alpha |
b |
parameter of Unif(0, b) for controlling censoring percentage |
l |
length for data generation (default = 300) |
A list with the following elements:
Subject |
a vector for numbers of subject |
T_ij |
a vector for event times |
delta_ij |
a vector for event indicator (=1 if recurrent; =0 if censoring) |
T_i_star |
a vector for death times |
delta_i_star |
a vector for death indicator (=1 if death; =0 if censoring) |
Xinwei Huang
Huang XW, Wang W, Emura T (2020) A copula-based Markov chain model for serially dependent event times with a dependent terminal event. Japanese Journal of Statistics & Data Science. Accepted.
Y = FrankFrank.Weibull.data(N = 100, scale1 = 1, shape1 =0.5, theta = 2, scale2 = 0.45, shape2 = 0.5, alpha = 2, b = 10, l = 300)
Y = FrankFrank.Weibull.data(N = 100, scale1 = 1, shape1 =0.5, theta = 2, scale2 = 0.45, shape2 = 0.5, alpha = 2, b = 10, l = 300)
Perform two-stage estimation based on the Frank copula C_theta for serial dependence and the Frank copula tilde(C)_alpha for dependent censoring with the marginal distributions Weib(scale1, shape1) and Weib(scale2, shape2). The jackknife method estimates the asymptotic covariance matrix. Parametric bootstrap is applied while doing Kolmogorov-Smirnov tests and Cramer-von Mises test. The guide for using this function shall be explained by Huang (2019), and Huang, Wang and Emura (2020).
FrankFrank.Weibull.MLE(subject, t.event, event, t.death, death, stageI, Weibull.plot, jackknife, plot, GOF, GOF.plot, rep.GOF, digit)
FrankFrank.Weibull.MLE(subject, t.event, event, t.death, death, stageI, Weibull.plot, jackknife, plot, GOF, GOF.plot, rep.GOF, digit)
subject |
a vector for numbers of subject |
t.event |
a vector for event times |
event |
a vector for event indicator (=1 if recurrent; =0 if censoring) |
t.death |
a vector for death times |
death |
a vector for death vindicator (=1 if death; =0 if censoring) |
stageI |
an option to select MLE or LSE method for the 1st-stage optimization |
Weibull.plot |
if TRUE, show the Weibull probability plot |
jackknife |
if TRUE, the jackknife method is used for estimate covariance matrix (default = TRUE) |
plot |
if TRUE, the plots for marginal distributions are shown (default = FALSE) |
GOF |
if TRUE, show the p-values for KS-test and CvM-test |
GOF.plot |
if TRUE, show the model diagnostic plot |
rep.GOF |
repetition number of parametric bootstrap |
digit |
accurate to some decimal places |
When jackknife=FALSE, the corresponding standard error and confidence interval values are shown as NA.
A list with the following elements:
Sample_size |
Sample size N |
Case |
Count for event occurences |
scale1 |
Scale parameter for Weib(scale1, shape1) |
shape1 |
Shape parameter for Weib(scale1, shape1) |
scale2 |
Scale parameter for Weib(scale2, shape2) |
shape2 |
Shape parameter for Weib(scale2, shape2) |
theta |
Copula parameter for the Frank copula C_theta |
alpha |
Copula parameter for the Frank copula tilde(C)_alpha |
COV |
Asymptotic covariance estimated by the jackknife method |
KS |
Kolmogorov-Smirnov test statistics |
p.KS |
P-values for Kolmogorov-Smirnov tests |
CM |
Cramer-von Mises test statistics |
p.CM |
P-values for Cramer-von Mises tests |
Convergence |
Convergence results for each stage |
Jackknife_error |
Count for error in jackknife repititions |
Log_likelihood |
Log-likelihood values |
Xinwei Huang
data = FrankFrank.Weibull.data(N = 300, scale1 = 1, shape1 =0.5, theta = 2, scale2 = 0.45, shape2 = 0.5, alpha = 2, b = 10, l = 300) FrankFrank.Weibull.MLE(subject = data$Subject, t.event = data$T_ij, event = data$delta_ij, t.death = data$T_i_star, death = data$delta_i_star, jackknife= TRUE, plot = TRUE)
data = FrankFrank.Weibull.data(N = 300, scale1 = 1, shape1 =0.5, theta = 2, scale2 = 0.45, shape2 = 0.5, alpha = 2, b = 10, l = 300) FrankFrank.Weibull.MLE(subject = data$Subject, t.event = data$T_ij, event = data$delta_ij, t.death = data$T_i_star, death = data$delta_i_star, jackknife= TRUE, plot = TRUE)