compare_plot | R Documentation |
Comparison plot generator This function help generate comparsion plot including bar plot, box plot, and violin plot
compare_plot(
inputframe,
treat_location,
value_location,
aes_col = NULL,
point = TRUE,
facet_location = NULL,
ylab_text = NULL
)
inputframe |
A data frame contain information for visualization. |
treat_location |
Numeric. Treatment column number in inputframe. |
value_location |
Numeric. Value column number in inputframe. |
aes_col |
Named character string, default:NULL. A set of aesthetic character to map treatment to. |
point |
Logical. If draw point on bar, box and violin plot. Default:TRUE. |
facet_location |
Numeric, default:NULL. Facet column number in inputframe. |
ylab_text |
Character. Text for y axis. |
A list contained plot and statistics
data("iris")
results=compare_plot(inputframe=iris,treat_location=5,
value_location=1,ylab_text = "Sepal Length")
#Check statistics
results$Statistics
#Extract plot
results$Barplot
results$Boxplot
results$Violinplot
iris$Treat2=rep(c(rep("A",25),rep("B",25)),3)
results=compare_plot(inputframe=iris,treat_location=5,
value_location=1,facet_location = 6,
ylab_text = "Sepal Length")
#Check statistics
results$Statistics
#Extract plot
results$Barplot
results$Boxplot
results$Violinplot
#Extract combined plot
results$All_Barplot
results$All_Boxplot
results$All_Violinplot
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.