Learn R Programming

eplusr (version 0.9.4)

install_eplus: Download and Install EnergyPlus

Description

Download specified version of EnergyPlus for your platform from GitHub and install it.

Usage

install_eplus(ver = "latest", force = FALSE)

download_eplus(ver = "latest", dir)

Arguments

ver

The EnergyPlus version number, e.g., 8.7. The special value "latest", which is the default, means the latest version.

force

Whether to install EnergyPlus even if it has already been installed.

dir

Where to save EnergyPlus installer file. For install_eplus(), the installer will be saved into tempdir()

Value

An invisible integer 0 if succeed. Moreover, some attributes will also be returned:

  • For install_eplus():

    • path: the EnergyPlus installation path

    • installer: the path of downloaded EnergyPlus installer file

  • For download_eplus():

    • file: the path of downloaded EnergyPlus installer file

Details

download_eplus() downloads specified version of EnergyPlus from EnergyPlus GitHub Repository.

install_eplus() will try to install EnergyPlus into the default location, e.g. C:\EnergyPlusVX-Y-0 on Windows, /usr/local/EnergyPlus-X-Y-0 on Linux, and /Applications/EnergyPlus-X-Y-0 on macOS.

Note that the installation process requires administrative privileges during the installation and you have to run R with administrator (or with sudo if you are on Linux) to make it work if you are not in interactive mode.

Examples

Run this code
# NOT RUN {
# for the latest version of EnergyPlus
download_eplus("latest", dir = tempdir())
install_eplus("latest")

# for a specific version of EnergyPlus
download_eplus(8.8, dir = tempdir())
install_eplus(8.8)
# }

Run the code above in your browser using DataLab