Description Usage Arguments Value Examples
View source: R/simulated_data.R
multi_LN_data
returns a list that includes a data frame of size [n,p+2]. The first p columns corresponds to the multivarite covarites Z, the p+1 column is the current status indicator, and the p+2 column is the censoring times. Note that when test=TRUE we get an extra column with the true uncensored failure time T.
1 | multi_LN_data(n, p = 10, tau = 7, test = FALSE, sigma = 1)
|
n |
A positive integer (sample size) |
p |
a positive integer indictating the dimension of the covariates. Default value is 10. |
tau |
A non-negative value (defining the support of T and C). Default value is 7. |
test |
Logical indicating whether the function should return in addition also the true (uncensored) failure time, together with Bayes risk, for testing. Default value is False and then only current status data is returned (for training). |
sigma |
A numeric value indicating the standard deviation of the log-normal distribution. |
A list containing: (1) the simulated data in the format of a data frame with the columns of the multivariate covariates Z, delta, C, and possibly also T (for testing only), and (2) the Bayes risk which can only be evaluated when test=TRUE (otherwise it is NA).
1 | d <- multi_LN_data(n=100)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.