User Tools

Site Tools


Install an external program within R

This is an example to download and install an external program / software within R.

dotRcheck <- function(){
  #Check for audiolyzR installation
  if (.Platform$OS.type=="windows"){
      ANSWER <- readline("Do you want to install Graphviz for path diagram generation? \nType y or n\n")
      if (substr(ANSWER,1,1)=="y"){
        tmpdir <- getwd()
        destfile<-paste(tmpdir, "graphviz-2.30.1.msi", sep="/")
        download.file("", destfile=destfile)
        shell(paste("msiexec /a ",destfile))              
You could leave a comment if you were logged in.

Page Tools