acc_sim {scR} | R Documentation |
Utility function to generate accuracy metrics, for use with estimate_accuracy()
Description
Utility function to generate accuracy metrics, for use with estimate_accuracy()
Usage
acc_sim(
n,
method,
p,
dat,
model,
eta,
nsample,
outcome,
power,
effect_size,
powersims,
alpha,
split,
...
)
Arguments
n |
An integer giving the desired sample size for which the target function is to be calculated. |
method |
An optional string stating the distribution from which data is to be generated. Default is i.i.d. uniform sampling. Currently also supports "Class Imbalance". Can also take a function outputting a vector of probabilities if the user wishes to specify a custom distribution. |
p |
If method is 'Class Imbalance', gives the degree of weight placed on the positive class. |
dat |
A rectangular |
model |
A function giving the model to be estimated |
eta |
A real number between 0 and 1 giving the probability of misclassification error in the training data. |
nsample |
A positive integer giving the number of samples to be generated for each value of $n$. Larger values give more accurate results. |
outcome |
A string giving the name of the outcome variable. |
power |
A logical indicating whether experimental power based on the predictions should also be reported |
effect_size |
If |
powersims |
If |
alpha |
If |
split |
A logical indicating whether the data was passed as a single data frame or separately. |
... |
Additional model parameters to be specified by the user. |
Value
A data frame giving performance metrics for the specified sample size.