An embedded and charset-unspecified text was scrubbed... Name: not available Url: https://stat.ethz.ch/pipermail/r-help/attachments/20071229/443c4bce/attachment.pl
Avoiding "." when importing from csv
3 messages · Thomas Schwander, Brian Ripley, Frank E Harrell Jr
1 day later
See the help, especially argument 'check.names'.
On Sat, 29 Dec 2007, Thomas Schwander wrote:
Hi guys, another question today: If I import an external csv-file with headers (with read.csv2), the blanks are interpreted as points. So "Test 1" becomes "Test.1". Is there a way to change this? Thanks, Thomas I'm using XP and R 2.6.1 [[alternative HTML version deleted]]
______________________________________________ R-help at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
PLEASE do (no HTML, for example).
Brian D. Ripley, ripley at stats.ox.ac.uk Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UK Fax: +44 1865 272595
Prof Brian Ripley wrote:
See the help, especially argument 'check.names'. On Sat, 29 Dec 2007, Thomas Schwander wrote:
Hi guys, another question today: If I import an external csv-file with headers (with read.csv2), the blanks are interpreted as points. So "Test 1" becomes "Test.1". Is there a way to change this? Thanks, Thomas
Depending on the ultimate need, you can also use the csv.get function in the Hmisc package. csv.get keeps the original column names as variable labels, then transforms the names to become legal R names as with read.csv. In the new version there is also an option to read the variable labels from another row. Frank Harrell