simulated | R Documentation |
The simulated function is used for specifying simulated input data and variables for VPC. Note: Simulated data must not
contain missing DV and may require filtering MDV == 0
before generating VPC. The ordering of observed and simulated
data must also be consistent, with replicates in simulated data stacked on top of each other.
simulated(o, ...)
## S3 method for class 'tidyvpcobj'
simulated(o, data, ysim, ..., xsim)
o |
A |
... |
Other arguments. |
data |
A |
ysim |
Numeric y-variable, typically named DV. |
xsim |
Numeric x-variable, typically named TIME. |
A tidyvpcobj
containing simulated dataset sim
formatted with columns x
, y
, and repl
, which indicates the replicate number.
The column x
is used from the observed()
function. Resulting dataset is of class data.frame
and data.table
.
observed
censoring
stratify
predcorrect
binning
binless
vpcstats
require(magrittr)
vpc <- observed(obs_data, x=TIME, y=DV) %>%
simulated(sim_data, y=DV)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.