plot,ihwResult-method | R Documentation |
See the vignette for usage examples.
## S4 method for signature 'ihwResult'
plot(
x,
x_axis = c(weights = "group", decisionboundary = "covariate")[what],
what = "weights",
scale = covariate_type(x)
)
x |
Object of class |
x_axis |
|
what |
|
scale |
|
A ggplot2
object.
save.seed <- .Random.seed; set.seed(1)
X <- runif(20000, min = 0.5, max = 4.5) # covariate
H <- rbinom(20000, 1, 0.1) # hypothesis true or false
Z <- rnorm(20000, H*X) # z-score
.Random.seed <- save.seed
pvalue <- 1-pnorm(Z) #pvalue
ihw_res <- ihw(pvalue, X, .1)
plot(ihw_res)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.