From pd@|gd @end|ng |rom gm@||@com  Fri Jul  9 10:00:56 2021
From: pd@|gd @end|ng |rom gm@||@com (peter dalgaard)
Date: Fri, 9 Jul 2021 10:00:56 +0200
Subject: [Rd] On read.csv and write.csv
In-Reply-To: <CWXP265MB32080AF023D38026656FB6AB811C9@CWXP265MB3208.GBRP265.PROD.OUTLOOK.COM>
References: <CWXP265MB3208A3DC3EE8F8E8489E258B81019@CWXP265MB3208.GBRP265.PROD.OUTLOOK.COM>
 <029F6720-64AB-4F19-A823-8DB0768E153F@R-project.org>
 <CWXP265MB32085A57128A1822E4A5C5BB81009@CWXP265MB3208.GBRP265.PROD.OUTLOOK.COM>
 <CAD4oTHFjYycJzEtLMM3jJ8ZbZjUCY6-Vh_-zUvHin3L15iXS1g@mail.gmail.com>
 <784D9F39-4215-4FC2-BCE4-FBEF52DCDB59@R-project.org>
 <CWXP265MB32080AF023D38026656FB6AB811C9@CWXP265MB3208.GBRP265.PROD.OUTLOOK.COM>
Message-ID: <44E757A8-CA4E-49D6-8C6F-12138531FC36@gmail.com>

?read.csv does actually have

row.names: a vector of row names.  This can be a vector giving the
          actual row names, or a single number giving the column of the
          table which contains the row names, or character string
          giving the name of the table column containing the row names.

-pd

> On 5 Jul 2021, at 12:37 , Stephen Ellison <S.Ellison at LGCGroup.com> wrote:
> 
>> From: Simon Urbanek <simon.urbanek at R-project.org>
>>     By default there is no column name for a column of row names.  
> <snip> 
>>     spreadsheets.  Note that such CSV files can be read in R by
>> 
>>       read.csv(file = "<filename>", row.names = 1)
> AHA!! Many thanks. 
> I see this clue is in ?write.table, though; I was looking for help on reading CSVs in ?read.csv etc. 
> <sigh>
> 
> Thanks to all for your time answering this; much appreciated.
> 
> S
> 
> 
> *******************************************************************
> This email and any attachments are confidential. Any u...{{dropped:21}}



[Rd] On read.csv and write.csv
peter dalgaard