Dave:
Thanks for the tip. Using commas instead of tabs to delimit the fields
was gumming up the works. Also, I was able to get all fields read as numbers
(instead of characters) using
colClasses=c("numeric",...
from the R manual. Success!
Ryan
------------------------------------------
Ryan T. Moore ~ Government & Social Policy
Ph.D. Candidate ~ Harvard University
On Wed, 8 Jan 2003 dkane(a)latte.harvard.edu wrote:
The R Manual and Import/Export of data is a great
source for things like this.
Best answer is probably to save the Excel file as tab-delimmited text and then
use read.table. If you are looking for a challenge, check out RODBC which
allows, I think, direct connections to things like Excel.
Dave
Ryan Thomas Moore writes:
Hello--
I'm trying to convert an Excel file to be R-usable. I can convert it into
a Stata or .dat or .txt "notebook" style file or whatever, no problem.
But, then when I try to read.table, I keep getting that the R object only has
one column! And, that "column" is all the data for that row, both numerical
and character. Any advice is much apppreciated.
Thanks,
Ryan
------------------------------------------
Ryan T. Moore ~ Government & Social Policy
Ph.D. Candidate ~ Harvard University
_______________________________________________
gov1000-list mailing list
gov1000-list(a)fas.harvard.edu
http://www.fas.harvard.edu/mailman/listinfo/gov1000-list
--
David Kane
Lecturer In Government
617-563-0122
dkane(a)latte.harvard.edu
Please avoid sending me Word or PowerPoint attachments.
See
http://www.fsf.org/philosophy/no-word-attachments.html