Could someone explain to me briefly and point me to where I can find help on what the symbols $ and % mean in R? I have seen them in many others' codes, but I am still very unsure as to what they mean and what they do. Thank you very much! -- Edward Chen Email: edchen51@gmail.com Cell Phone: 510-371-4717 [[alternative HTML version deleted]]
Edward Chen-3 wrote:> > Could someone explain to me briefly and point me to where I can find help > on > what the symbols $ and % mean in R? I have seen them in many others' > codes, > but I am still very unsure as to what they mean and what they do. > Thank you very much! > >Help pages for symbols like if, for, [, <-, $ can be accessed in the same way as help pages for functions. A pair of % signs is usually used to delimit a special unary or binary operator-- such as %*% which invokes matrix multiplication. However, since these symbols have special meaning, they must be quoted when placed next to ? or ??-- like so: ?"$" ??"%" - Charlie ----- Charlie Sharpsteen Undergraduate Environmental Resources Engineering Humboldt State University -- View this message in context: http://www.nabble.com/help-with-%24-and---symbols-in-R-tp25515775p25516043.html Sent from the R help mailing list archive at Nabble.com.
On Sep 18, 2009, at 5:24 PM, Edward Chen wrote:> Could someone explain to me briefly and point me to where I can find > help on > what the symbols $ and % mean in R? I have seen them in many others' > codes, > but I am still very unsure as to what they mean and what they do. > Thank you very much!For "$" you can just try: ?"$" # ... and get information on the extraction operators. For "%", it is not an operator itself but "%%" is; as is "%in%"; as are other infix operators, and help pages for them can be brought up in a similar fashion. ?"%%" ?"%in%" -- David Winsemius, MD Heritage Laboratories West Hartford, CT