Learn R Programming

Ryacas (version 0.2-11)

yacasInstall: Install yacas files needed by Ryacas

Description

Download the script.dat and yacas.exe files needed by Ryacas.

Usage

yacasInstall(url = "http://ryacas.googlecode.com/files/yacas-1.0.63.zip",
   overwrite = FALSE)
yacasFile(filename = c("yacas.exe", "scripts.dat", "R.ys"),
   slash = c("\\", "/"))

Arguments

Value

yacasInstall has no return value. yacasFile returns the full pathname of the indicated yacas file or the location where it would be if it were installed. For yacas.exe this is the contents of the environment variable YACAS_HOME or if that is not defined then it is the folder system.file(package = "Ryacas", "yacdir"). For scripts.dat this is the contents of the environment variable YACAS_SCRIPTS, or if that is not defined, it is the folder where yacas.exe is located or would be located. For R.ys this is the contents of the environment variable YACAS_INIT, or if that is not defined, it is located in system.file(package = "Ryacas", "yacdir"). Note that R.ys is included with Ryacas since it is a text file but scripts.dat is not included since it is a binary file which is why their default locations differ. yacasCheck returns 0 if the yacas files, yacas.exe and scripts.dat were found in yacasFile("yacas.exe") and yacasFile("scripts.dat"), -1 if they were not found and 1 if they were found but have the wrong file size. If the user specifies the YACAS_INVOKE_STRING environment variable then it will not be able to perform the check in which case NA is returned.

Details

yacasInstall downloads a zip file and extracts yacas.exe and scripts.dat installing them into yacasFile("yacas.exe") and yacasFile("scripts.dat").

Examples

Run this code
Sys.getenv("YACAS_INVOKE_STRING")
Sys.getenv("YACAS_HOME")
Sys.getenv("YACAS_SCRIPTS")
system.file(package = "Ryacas", "yacdir")
yacasFile("yacas.exe")
yacasFile("scripts.dat")
yacasInstall()

Run the code above in your browser using DataLab