[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [igraph] how to read mutibple graph data into R
From: |
Csardi Gabor |
Subject: |
Re: [igraph] how to read mutibple graph data into R |
Date: |
Fri, 19 Sep 2008 09:05:30 +0200 |
User-agent: |
Mutt/1.5.9i |
Read them in a loop or lapply.
The list of files can be obtained with the list.files() function. So,
it is something like this:
files <- list.files("<your-directory-here>")
graphs <- lapply(files, read.graph, format="<your-format>")
You will get a list called 'graphs' including all the graphs.
Gabor
On Thu, Sep 18, 2008 at 03:28:13PM -0500, lan gao wrote:
> Hey, all
> I have about 70 graph data files under one folder:
> files names look like this
>
> yeast20071107.lst
> yeast20070511.lst
> yeast20060420.lst
> yeast20060104.lst
> .................
>
> I need to read all these files into R then combine them.
>
> Can anybody help me out? Many thanks.
> _______________________________________________
> igraph-help mailing list
> address@hidden
> http://lists.nongnu.org/mailman/listinfo/igraph-help
--
Csardi Gabor <address@hidden> MTA RMKI, ELTE TTK