Bert Gunter <gunter.berton <at> gene.com> writes: > > Eh??? Why would you want to do that?? (R isn't C). > > So the simple answer is: you can't. > > The other answer is, well of course you sort of can via, e.g. > > for(i in 0:9) { > z <- myMatrix[i+1,] > ... > } > > But as Josh said, I think this falls into the class of "You are just > asking for trouble, so don't do it." > > Cheers, > Bert
But if you still want to after all those warnings, you can ... see the "Oarray" package, where the first letter of the package name is a capital letter "oh" (O), not a zero (0). library("fortunes"); fortune("Yoda") There ought also to be a clever fortune() expressing the sentiment that you may eventually find (weeks, months, or years later) that changing the way you solve your problem to go with R's flow would have been easier than implementing a solution that works around the flow (examples abound: <<-, zero-based arrays, eval(parse()), storing names of variables as character vectors and using get() [FAQ 7.21], etc, etc, etc ...) ______________________________________________ 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-contained, reproducible code.