[R] about the char _

Gerard.Keogh@cso.ie Gerard.Keogh at cso.ie
Fri Oct 5 10:50:42 CEST 2001


Yes I agree with Fan. For those of us (new to R and) who also use SAS, the
underscore is an ideal way to create variable names. In fact it provides a
good convention for naming global variables in code that is written to be
called by  say another "users" program. R's use of the "." to concatenate
names is useful to distinguish variable levels but I think that being able
to name an object  _myfun.x1 would be a great asset in future versions of
R.

Gerard Keogh




                                                                                                                        
                    Fan                                                                                                 
                    <xiao.gang.fan1 at liber        To:     r-help at stat.math.ethz.ch                                       
                    tysurf.fr>                   cc:                                                                    
                    Sent by:                     Subject:     [R] about the char _                                      
                    owner-r-help at stat.mat                                                                               
                    h.ethz.ch                                                                                           
                                                                                                                        
                                                                                                                        
                    05/10/01 00:23                                                                                      
                                                                                                                        
                                                                                                                        




Dear all,

I don't know the historical reason why the char '_' was
defined in the R language grammar as a synonyme of the
assignment <-, anyway the R documentation dosen't recommand
its usage.

Well, this is a real "incompatibility issue" each time
we need to interface R with other language/systems, notably with
database systems. Recall that, in perhaps all computer systems,
the char '_' can be used in the name of a variable or a column
in a data table.

So that's my question : is there an option to change this
behaviour ?

All that I want is the possibility to use the same name of
variables in my R source as they are declared in the other systems.

Thanks
--
Fan
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.
-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._.
_._._




The information in this email, and any attachments transmitted with it, are confidential 
and are for the intended recipient only. If you receive this message in error, please 
notify us via postmaster at cso.ie.

To see the latest figures from the CSO go to http://www.cso.ie
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._



More information about the R-help mailing list