Newer
Older
<!-- README.md is generated from README.Rmd. Please edit that file -->
# capriv
<!-- badges: start -->
<!-- badges: end -->
The goal of capriv is to draw sankey charts, related tables and capri maps.
## Installation
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
### Requirements
- TIDYKML: tidykml reads selected elements and values from KML files.
- GDXRRW: GDXRRW is an interface between General Algebraic Modeling System (GAMS) and R, it transfers data between GAMS and R and calls gams from within R.
- GAMS environment system: It operations on GAMS data.
- CAPRIR: capriR is a tool for processing, visualizing and analysing both the databases and simulation results of CAPRI.
``` r
# The R devtools package allows packages that are hosted on GitHub to be installed directly from there.
install.packages("devtools")
library(devtools)
# tidykml
devtools::install_github("briatte/tidykml")
library(tidykml)
# Installation gdxrrw from GitHub
devtools::install_github("GAMS-dev/gdxrrw/gdxrrw")
# Or installation from website: <https://support.gams.com/gdxrrw:interfacing_gams_and_r>, then download the required file and point to the specific path of the file.
install.packages("D:/public/yang/CAPRIR_Project/gdxrrw_1.0.5.zip", repos = NULL, type="source")
# Checking if gdxrrw is installed For GAXRRW to work it must be load shared libraries from the GAMS System directory.
library(gdxrrw)
# The igdx command can be used to show what GAMS system directory GDXRRW has found.
igdx()
# if GDX library has not been loaded, tell where is located GAMS.
igdx("D://gams//win64//24.9")
# caprir
devtools::install_git("https://git-dmz.thuenen.de/mindstep/caprir.git")
library(caprir)
```
You can install the released version of capriv from [Thünen Gitlab](https://git-dmz.thuenen.de/mindstep/capriv.git) with:
devtools::install_git("https://git-dmz.thuenen.de/mindstep/capriv.git")
# load packages
requiredPackages = c('caprir','gdxrrw', 'usethis','hablar', 'tibble','networkD3','readxl','tidyr','dplyr','reshape2','data.table','plotly','webshot','gt')
for(p in requiredPackages){
if(!require(p,character.only = TRUE)) install.packages(p)
library(p,character.only = TRUE)
}
## References
- <https://git-dmz.thuenen.de/capri/capri_reports>
- <https://github.com/trialsolution/caprir>