[R] R2WinBUGS

2012-07-17 Thread PRAGYA SUR
Dear R users, Can anyone tell me why I might get the error message the array index is greater than the upper bound for t in WinBUGS ? t is a vector I have defined. I have checked repeatedly that the array index for t does match with the upper bound till which the loop is run. I

[R] Accessing coefficient values in linear regression

2012-07-12 Thread PRAGYA SUR
Hi everyone, I am fitting a simple linear regression model in R. My command is j=lm( Y ~ Sex + begsal + time + int) Call: lm(formula = Y ~ Sex + begsal + time + int) Coefficients: (Intercept) Sex begsal time int 191.916 -241.805

[R] R to winbugs interface

2012-07-09 Thread PRAGYA SUR
Hello everyone, I need some help regarding calling WinBUGS from R. I have a model for WinBUGS and an R code which calls WinBUGS. On running the code I am being shown the error message : Error in file(con, wb) : cannot open the connection In addition: Warning messages: 1: In

Re: [R] R to winbugs interface

2012-07-09 Thread PRAGYA SUR
I ran the same program in a different computer where it had run proper a week ago. This time around in the log file in WinBUGS the program stopped at a line which said : save(C:/DOCUME~1/ADMINI~1/LOCALS~1/Temp/RtmpU3u46p/log.odc) save(C:/DOCUME~1/ADMINI~1/LOCALS~1/Temp/RtmpU3u46p/log.txt) and did

Re: [R] R to winbugs interface

2012-07-09 Thread PRAGYA SUR
: On 09.07.2012 18:19, PRAGYA SUR wrote: I ran the same program in a different computer where it had run proper a week ago. This time around in the log file in WinBUGS the program stopped at a line which said : save(C:/DOCUME~1/ADMINI~1/**LOCALS~1/Temp/RtmpU3u46p/log.**odc) save(C:/DOCUME~1/ADMINI~1

[R] returning multiple values

2012-07-09 Thread PRAGYA SUR
I am running a program which has an output containing four vectors named meanfevs, meanfevns, pfevs, pfevns. I wish to return all four and be able to access them later. I used the command return(list(a=meanfevs,b=meanfevns,c=pfevs,d=pfevns)) it did give me the ouput. However the values did not get