lrt {clikcorr} | R Documentation |
censoring data and likelihood-based correlation estimation inference
Description
Provides likelihood ratio tests for making statistical inference about the correlation coefficient from bivariate censored/missing data.
Usage
lrt(data, lower1, upper1, lower2, upper2, dist = "n", df = 4,
sv = NA, r0 = 0, nlm = FALSE, ...)
Arguments
data |
a data frame name. |
lower1 |
the lower bound of the first of the two variables whose correlation coefficient to be calculated. |
upper1 |
the upper bound of the first of the two variables whose correlation coefficient to be calculated. |
lower2 |
the lower bound of the second of the two variables whose correlation coefficient to be calculated. |
upper2 |
the upper bound of the second of the two variables whose correlation coefficient to be calculated. |
dist |
working distribution. By default, |
df |
degree of freedom of the bivariate t-distribution when |
sv |
user specified starting values for the vector of (mean1, mean2, var1, corr, var2). |
r0 |
correlation coefficient value under the null hypothesis. By default is 0. |
nlm |
use |
... |
not used. |
Value
Cor |
maximum likelihood estimate (MLE) of the correlation coefficient. |
m1llk |
value of the log likelihood function evaluated at the MLE. |
m0llk |
value of the log likelihood function evaluated at the r0. |
P0 |
p-value for likelihood ratio test with null hypothesis says that the true correlation coefficient equals r0. |
Author(s)
Yanming Li, Kerby Shedden, Brenda W. Gillespie and John A. Gillespie.
References
Yanming Li, Kerby Shedden, Brenda W. Gillespie and John A. Gillespie (2016). Calculating Profile Likelihood Estimates of the Correlation Coefficient in the Presence of Left, Right or Interval Censoring and Missing Data.
Examples
data(ND)
logND <- log(ND)
lrt(logND, "t1_TCDD", "t2_TCDD", "t1_PeCDD", "t2_PeCDD")
## Not run:
lrt(logND, "t1_TCDD", "t2_TCDD", "t1_PeCDD", "t2_PeCDD", dist="t")
## End(Not run)