Re: [R] Q: appending to non-existent vector?

2007-09-21 Thread Ted Harding
On 21-Sep-07 17:15:08, D. R. Evans wrote: > This is a real newbie question. What makes it worse is that I know > I've seen the answer somewhere, but I can no longer find it. > > If I have a loop that is supposed to generate a vector piecemeal, > adding an element each time through the loop, what d

Re: [R] Q: appending to non-existent vector?

2007-09-21 Thread D. R. Evans
OK; lots of ideas there. Thanks very much. Doc __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-containe

Re: [R] Q: appending to non-existent vector?

2007-09-21 Thread hadley wickham
On 9/21/07, Duncan Murdoch <[EMAIL PROTECTED]> wrote: > On 9/21/2007 1:15 PM, D. R. Evans wrote: > > This is a real newbie question. What makes it worse is that I know > > I've seen the answer somewhere, but I can no longer find it. > > > > If I have a loop that is supposed to generate a vector pie

Re: [R] Q: appending to non-existent vector?

2007-09-21 Thread Duncan Murdoch
On 9/21/2007 1:15 PM, D. R. Evans wrote: > This is a real newbie question. What makes it worse is that I know > I've seen the answer somewhere, but I can no longer find it. > > If I have a loop that is supposed to generate a vector piecemeal, > adding an element each time through the loop, what do

Re: [R] Q: appending to non-existent vector?

2007-09-21 Thread Greg Snow
.D. Statistical Data Center Intermountain Healthcare [EMAIL PROTECTED] (801) 408-8111 > -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of D. R. Evans > Sent: Friday, September 21, 2007 11:15 AM > To: [EMAIL PROTECTED] > Subject: [R] Q: app

[R] Q: appending to non-existent vector?

2007-09-21 Thread D. R. Evans
This is a real newbie question. What makes it worse is that I know I've seen the answer somewhere, but I can no longer find it. If I have a loop that is supposed to generate a vector piecemeal, adding an element each time through the loop, what do I do to stop it failing the first time around the