get_runs_data: Get model results for different modelruns,

View source: R/IO.R

get_runs_dataR Documentation

Get model results for different modelruns,

Description

Function to get modelresults for the same location and variables for multiple runs

Usage

get_runs_data(runs, locs, vars)

Arguments

runs

dataframe containing columns <path> and <tag>"

locs

list of locations to be be extracted

vars

list of variables to be be extracted

filename

the name of the file containg the binairy output

Value

A dataframe with model output values for submod and locmod.

Examples

library(Waternet)
filename  <- c("data/testdata.his",
               "data/testdata2.his")
tag      <- c("run 1",
              "run 2")
runs <- data.frame(filename, tag)
submod <- c("OXY", "Cl")
locmod <- c("LOX003","LOX009")
df <- get_model_data("data/testdata.his", locmod, submod)
library(ggplot2)
plot <- ggplot(df, aes(time, value)) +
  geom_line(aes(color = variable), size = 1) +
  facet_grid((variable ~ location), scales = "free")
plot

EMMeijers/Waternet documentation built on Nov. 19, 2022, 1:36 p.m.