plot.ObjFct {ModelDataComp} | R Documentation |
Barplot or scatterplot of objective function metrics. A barplot is created if only one metric is defined in which
. A scatterplot is created if two metrics are defined.
## S3 method for class 'ObjFct' plot(x, which = c("Cor", "KS", "AE"), alpha = 0.1, cols = "black", pch = NULL, legend = TRUE, xlab = NULL, ylab = NULL, xlim = NULL, ylim = NULL, txt = NULL, add = FALSE, ...)
x |
an object of class |
which |
Which objective function metrics should be plotted? If one metric is defined, a barplot will be plotted. If more than one metric is defined, the first metric will be used for the x-axis and the second metric for y-axis of a scatterplot. If a third metric is specified, point sizes in the scatterplot will be scaled. |
alpha |
significance level to plot objetive functions that are not significant different from the optimum with different point symbols. This only works if the the selected objective functions in which have a p-value. Set to NULL to avoid this option. |
cols |
colors for the groups |
pch |
point symbols for scatterplots or for pointsplots (instead of barplot) |
legend |
plot a legend for the significance point symbols? |
xlab |
label for x-axis |
ylab |
label for y-axis |
xlim |
limits for x-axis |
ylim |
limits for y-axis |
txt |
text for the points |
add |
add plot to an existing plot? This only works for scatterplots. |
... |
further arguments to |
No details.
Matthias Forkel <matthias.forkel@geo.tuwien.ac.at> [aut, cre]
No reference.
ObjFct
, TaylorPlot
, ScatterPlot
, WollMilchSauPlot
# create some data obs <- 1:300 sim <- obs * c(rnorm(100, 1, 0.1), rnorm(100, 1, 0.3), rnorm(100, 1, 0.5)) groups <- c(rep("subset 1", 100), rep("subset 2", 100), rep("subset 3", 100)) ScatterPlot(sim, obs, groups, objfct=TRUE) of <- ObjFct(sim, obs, groups) of # default plot plot(of) # barplots with only one metric plot(of, "Cor") plot(of, "AE") plot(of, "MEF") # options for the scatterplot: plot(of, c("Cor", "RMSE", "MEF")) plot(of, c("Spearman", "KS"), alpha=0.05) plot(of, c("Spearman", "KS"), alpha=NULL) plot(of, cols=c("black", "red", "blue", "green")) plot(of, c("Cor", "FV"), pch=0:4)