Can anyone suggest what might be going wrong here?
Operating system: Win 7
R version: R-3.2.4.
rstan version: 2.15.1
rtools version: 3.2.0.1948
A. I’ve had stan/Rstan running for a long time on
this computer. When I’m logged in I can
successfully compile/run a script that sets up and
runs the famous 8schools example under RStudio.
B. I recently added a second user – also an administrator –
to the system. However, when I try to run the same 8schools
script when logged in as this user, I consistently get an error:
fit<- stan(file=“8schools.stan”,
-
data=stan_data,iter=2000, chains=4, cores=cores)
Error in file(con, “r”) : cannot open the connection
In addition: Warning messages:
1: running command ‘C:/PROGRA~4/R/R-32~1.4/bin/x64/R CMD SHLIB file1785a23362d.cpp 2> file1785a23362d.cpp.err.txt’ had status 65535
2: In file(con, “r”) :
cannot open file ‘file1785a23362d.cpp.err.txt’: No such file or directory
This occurs with all other scripts too; not just
8schools. So far I’ve checked that the second user:
- has RTools appropriately in the path
- that system(‘g++ -v’) produces the expected output ; as does system(‘where make’)
- can write to each directory in the RTools folder (if that matters)
- can run z<-stanc(file=“8schools.stan”) apparently without error.
Also, the same problem arises in the default Rgui, so it doesn’t seem to be an RStudio problem.
Can anyone suggest what is going wrong here? Where is the .cpp file being written to? Could that be an issue? Is it possible that rstan has “learned” to use some folders that apply only to the first user, and which may be unavailable to the second user (eg the location of first user’s the TEMP/TMP folder)?
Thanks for any help/suggestions!