Thanks, David & Jean
assign(), as you suggested works to create the named objects in the
global environment.
In my application, I also want to :
(a) save each object to a similarly-named .RData file with that object
(b) create a corresponding .Rd documentation file.
(b) works fine in my loop
Hi:
Hmm, these files look familiar...Lahman database? :)
I have the 2010 set, so here's how I got this to work on my system:
files <- list.files(pattern = '*.csv')
> files
[1] "Allstar.csv" "AllstarFull.csv"
[3] "Appearances.csv" "AwardsManagers.csv"
[5] "AwardsPlayers.csv
Michael Friendly wrote on 09/09/2011 09:39:27 AM:
>
> I have a collection of .csv files in a directory, and want to read them
> into R data.frames whose names
> are the same as the file names, without the .csv extension
>
> e.g., from
> > (files <- list.files(pattern="*.csv"))
> [1] "Allstar
On Sep 9, 2011, at 10:39 AM, Michael Friendly wrote:
I have a collection of .csv files in a directory, and want to read
them into R data.frames whose names
are the same as the file names, without the .csv extension
e.g., from
> (files <- list.files(pattern="*.csv"))
[1] "Allstar.csv"
I have a collection of .csv files in a directory, and want to read them
into R data.frames whose names
are the same as the file names, without the .csv extension
e.g., from
> (files <- list.files(pattern="*.csv"))
[1] "Allstar.csv" "AllstarFull.csv"
[3] "Appearances.csv" "A
5 matches
Mail list logo