Description Usage Arguments Value Author(s) See Also Examples
View source: R/validationPlot.R
Function to create a validation plot from magpie outputs.
1 2 3 4 5 |
func |
Name of the magpie library function that this data belongs to. |
... |
Values for arguments that func takes. If an argument is not specified the default value are used if existing. Otherwise an error will occur. The two arguments "file" and "level" can be omitted without causing problems. |
historical |
Determines what kind of data is returned. Either historical data (TRUE), projections (FALSE) or both (NULL). |
datasources |
A vector containing the names of the datasets that shall be returned. If NULL (default) all datasets are returned. |
years |
A vector specifying the first and last year displayed. Has to be provided as integer years, eg: years=c(1980,2045). For one sided limits, set the other one to NA, e.g. c(NA,2065) or c(1960,NA). |
xlim |
Similar to the years argument. For back compatibility only. |
ylim |
A vector specifying limits for the y axis. |
index |
Y axis diesplays absolute values (FALSE) or index wrt to model output in the first simulation year (TRUE) |
same_yscale |
If level=="reg", should all regions have the same y axis (TRUE) or individual ones (FALSE). |
text_size |
Size of the text in the plot |
title |
Title of the plot. If NULL, the title will be determined automatically from the comparison data. |
legend_names |
NULL or a vector of length three. Determines the legend titles for Model output, Historical data and Other projections. If NULL, the default titles will be used. |
raw_plot |
If FALSE, the complete plot is returned. If TRUE, a list with the actual plot, the legend and the
function to combine both is returned. See |
raw_legend |
Works only with raw_plot=TRUE. If FALSE, the complete legend is returned. If TRUE, a list with the individual legend components and the function to combine both is returned. See |
withTL |
TRUE or FALSE. If TRUE, results of the |
An object of the class ggplot is returned. Executing 'print' on it will show the plot. If raw_plot=TRUE
, a list is returned (see histoPlot
).
Markus Bonsch
addData
,getData
,histoPlot
,addMapping
,trafficLight
1 | ## Not run: print(validationPlot(func=land,gdx="fulldata.gdx",type="crop"),level="glo")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.