add barebones results bar chart
This commit is contained in:
22
charts/single_result.r
Normal file
22
charts/single_result.r
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
library(ggplot2)
|
||||||
|
|
||||||
|
# Usage: Rscript single_result.r exp_abspath
|
||||||
|
|
||||||
|
args <- commandArgs(trailingOnly = TRUE)
|
||||||
|
experiment <- args[1]
|
||||||
|
datafile <- paste(experiment, "/resultsdata.csv", sep = "")
|
||||||
|
|
||||||
|
if (!file.exists(datafile)) {
|
||||||
|
print(paste("Input file", datafile, "is missing"))
|
||||||
|
stop()
|
||||||
|
}
|
||||||
|
|
||||||
|
data <- readr::read_csv(datafile)
|
||||||
|
|
||||||
|
plot <- ggplot(data, aes(x = benchmark, y = faults, fill = resulttype)) +
|
||||||
|
geom_col(position = "dodge") +
|
||||||
|
scale_y_log10() +
|
||||||
|
labs(x = "Benchmark", y = "Faults", fill = "Result Type") +
|
||||||
|
theme_minimal()
|
||||||
|
|
||||||
|
ggsave(paste(experiment, "/single_result.svg", sep = ""), plot = plot)
|
||||||
Reference in New Issue
Block a user