From: Alex Gutteridge Date: 2006-10-17T11:03:18+09:00 Subject: Re: [ANN] RSRuby 0.4 On 16 Oct 2006, at 22:39, hadley wickham wrote: >> require 'rsruby' >> r=RSRuby.instance #Create R interpreter >> ttest = r.t_test([1,2,3]) #Convert [1,2,3] to R. Run >> t.test > > Also, calling t_test instead of t.test is a bit worrying, suggesting > that you are automatically converting _ to . - not a good idea! > > Hadley Hmmm. Yes 't_test' is automatically converted to 't.test'. Again, this is the system used by RPy, which I have been slavishly copying - perhaps it is non-optimal. The current release doesn't have an option to turn off the automatic function name conversion but it would be very easy to add. Many (the majority?) of the R functions I've seen use '.' as a word separator, but I agree it is naive to think that all functions will do this. The automatic conversion will stay in though because it is much prettier (in my opinion) to write: r.t_test([1,2,3]) than the alternative: r['t.test'].call([1,2,3]) If you can think of another scheme for calling these kind of methods then I'd be happy to hear it. Dr Alex Gutteridge Post-Doctoral Researcher Bioinformatics Center Institute for Chemical Research Kyoto University Gokasho, Uji, Kyoto 611-0011 Japan