[R] Extracting Header From Table
John Fox
jfox at mcmaster.ca
Tue Aug 6 05:20:33 CEST 2002
Dear Mathew,
At 12:44 AM 8/6/2002 +0100, Dowle, Matthew [EQRE] wrote:
>Peter,
>Try colnames(Table). Beware if you had used lower case t you would have
>masked the table() R function.
>Rgds,
>Matthew
Actually, a variable named table defined in the global environment won't
mask a function of the same name in an attached package.
John
>-----Original Message-----
>From: PLauren at genelogic.com [mailto:PLauren at genelogic.com]
>Sent: 05 August 2002 21:12
>To: r-help at stat.math.ethz.ch
>Subject: [R] Extracting Header From Table
>
>
>I read a tab-delimited ASCII table, with a header, into R thus.
>Table <- read.table(FileName, header=TRUE, sep="\t");
>
>Is there any way I can now retrieve the header. The header information is
>obviously there since I see it, along with the values of the first row of
>data, when I type
>Table[1, ]
>
>However, I cannot find an R function to retrieve the header information
>from "Table". When I try
> > help.search("header")
>
>I get
>No help files found with alias or title matching `header'
>
>I would be grateful if someone could tell me how I might retrieve the
>header information.
>
>Thanks,
>Peter.
>==========================================================================
>== The information contained in this email message is intended only for
>use by the ==
>== recipient(s) to which it is addressed. This message may be privileged
>and ==
>== confidential and protected from disclosure. If the reader of this
>message is not ==
>== the intended recipient or an agent responsible for delivering it to the
>intended ==
>== recipient, you are hereby notified that you have received this
>document in error ==
>== and that any review, retransmission, dissemination, distribution,
>copying or other ==
>== use of, or taking of any action in reliance upon this information, is
>strictly ==
>== prohibited. If you have received this communication in error, please
>contact the ==
>== sender and delete the material from your computer.
>==
>==========================================================================
>
>
>-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.
>-.-
>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
>_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._.
>_._
>-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
>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
>_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
-----------------------------------------------------
John Fox
Department of Sociology
McMaster University
Hamilton, Ontario, Canada L8S 4M4
email: jfox at mcmaster.ca
phone: 905-525-9140x23604
web: www.socsci.mcmaster.ca/jfox
-----------------------------------------------------
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
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