Thanks Bill and Simon. I wrote a simpler function to test and found out it
was stepAIC which causes error, and I still don't know how to solve it.
Check out this simple function:
myfun-function(k){
xx-mvrnorm(100,rep(0,10),diag(1,10),empirical=TRUE)
colnames(xx)-paste(x,1:10,sep='')
Your example works for me without any error messages in R 2.3.1 with the
current (uncredited) MASS package 7.2-27.1, including giving about 20 'ok
here.'.
Did you heed the advice in the posting guide to update (as well as to tell
us the versions of things you were using)? Probably not (as you
After I updated my R from 2.2.0 to 2.3.1, it is working fine now. Thanks!
Mike
On 8/23/06, Prof Brian Ripley [EMAIL PROTECTED] wrote:
Your example works for me without any error messages in R 2.3.1 with the
current (uncredited) MASS package 7.2-27.1, including giving about 20 'ok
here.'.
Mike Wolfgang asks:
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Mike Wolfgang
Sent: Wednesday, 23 August 2006 1:31 PM
To: R-help list
Subject: [R] glm inside one self-defined function
Hi list,
I've searched in R-help and found some related discussions but still
could