appResults is a Shiny app for exploring and visualizing
time series of modelling results (mainly from MAgPIE or REMIND). It is
configured via an R option called appResults that you
typically set in your .Rprofile.
Create a named list with one entry per model and pass it to
options(appResults = ...). Each entry is itself a list with
these fields:
| Field | Description |
|---|---|
file |
URL or path to an RDS overview file listing all available runs. Use
reduced_overview.rds for faster loading or
overview.rds for the full set of filters. |
resultsfolder |
URL or path to the folder containing the individual run result files (RDS). |
valfile |
Validation data — an RDS file containing a quitte object or a
CSV/MIF file. NULL lets users upload files inside the app.
Can be a named character vector for multiple validation files. |
username |
Username for HTTP authentication. |
password |
Password for HTTP authentication. |
selectionSets |
Optional named list of predefined filter sets per column. Each element maps a label to a character vector of values. |
.Rprofileurl <- "https://rse.pik-potsdam.de/data/magpie/results/rev1"
options(appResults = list(
MAgPIE = list(
file = paste0(url, "/reduced_overview.rds"),
resultsfolder = url,
valfile = c(
"H12" = paste0(url, "/validation.rds"),
"H16" = paste0(url, "/validation_H16.rds")
),
username = "myuser",
password = "mypassword"
)
))For actual MAgPIE / REMIND configuration values, check the internal wiki page.
You can override any config field named arguments passed to
appResults:
Other arguments:
readFilePar — TRUE to
read report files in parallel (faster), FALSE (default) for
sequential reading.variableConfig — path to a custom YAML
file with variable presets (see below). NULL uses the
default config.port — port number for the Shiny app
(default 3838). A fixed port makes bookmarked URLs stable.Use selectionSets to define shortcuts for common filter
selections. Each entry maps a filter column to a named list of value
vectors:
appResults loads variable presets that populate the
Dashboard tab and the quick-load menus in plot tabs. The lookup order
is:
variableConfig.~/.shinyresults/variables.yaml.inst/extdata/variables_default.yaml).A configuration file looks like this:
meta:
version: "1.0"
description: "My custom presets"
presets:
land_cover:
name: "Land Cover"
description: "Land cover types and changes"
variables:
- variable: "Resources|Land Cover|+|Cropland"
plot_type: "line"
- variable: "Resources|Land Cover|+|Forest"
plot_type: "line"
emissions:
name: "GHG Emissions"
variables:
- variable: "Emissions|CO2|Land|+|Land-use Change"
plot_type: "line"Each preset has a name, an optional
description, and a list of variables entries
with variable (the variable name) and
plot_type (defaults to "line").