plot_anova {sprtt} | R Documentation |
Plot Sequential ANOVA Results
Description
Creates plots for the results of the seq_anova() function.
Usage
plot_anova(
anova_results,
labels = TRUE,
position_labels_x = 0.15,
position_labels_y = 0.075,
position_lr_x = 0.05,
font_size = 25,
line_size = 1.5,
highlight_color = "#CD2626"
)
Arguments
anova_results |
result object of the seq_anova() function (argument must be of class |
labels |
show labels in the plot. |
position_labels_x |
position of the boundary labels on the x-axis. |
position_labels_y |
position of the boundary labels on the y-axis. |
position_lr_x |
scales the position of the LR label on the x-axis. |
font_size |
font size of the plot. |
line_size |
line size of the plot. |
highlight_color |
highlighting color, default is "#CD2626" (red). |
Value
returns a plot
Examples
# simulate data for the example ------------------------------------------------
set.seed(333)
data <- sprtt::draw_sample_normal(3, f = 0.25, max_n = 30)
# calculate the SPRT -----------------------------------------------------------
anova_results <- sprtt::seq_anova(y~x, f = 0.25, data = data, plot = TRUE)
# plot the results -------------------------------------------------------------
sprtt::plot_anova(anova_results)
sprtt::plot_anova(anova_results,
labels = TRUE,
position_labels_x = 0.5,
position_labels_y = 0.1,
position_lr_x = -0.5,
font_size = 25,
line_size = 2,
highlight_color = "green"
)
sprtt::plot_anova(anova_results,
labels = FALSE
)
[Package sprtt version 0.2.0 Index]