This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Help on reading MAGE-TAB file to be used in the WGCNA

Hello evereyone!

I'm a graduate student from the Ceará State University in Brazil, and my dissertation is about gene expression and eigengenes. I'm new to this field and I'm learning everyday about this topic.

For my dissertation I'm using the R package WGCNA to build gene networks and eigengene modules. The gene expression data I'm using is from an ArrayExpress MAGE-TAB file and here is my problem.

The MAGE-TAB file is a tab-delimited file, while the WGCNA only reads comma-delimited files, as far as I can tell. How can I read this file in the R environment?

I did several different tutorials to learn how to use the WGCNA, but I can't find a way to read this file so I can start building my gene network.

I really appreciate all the help I can get!

mage-tab wgcna

1 answer

Would a read.table instead of a read.csv not help you with this? From the tutorial here, I see they're using the regular read methods for data input. Is there a different place where the input is restrictive to CSV only?

If that's the case, you can always cat INPUT | tr "\t" "," >tsvAsCsv.csvthe input file.

I can confirm that there's no imposition of CSV format by WGCNA. I just checked an old experiment where I used it and the 7th line of the script (including the shebang and blank lines) uses read.delim().

RamRS,

So simple and yet I couldn't see it! I tried the "read.table" and it worked!

I'll try the other code you placed here!

I guess I have to study a little more!

Thanks a lot!

DevonRyan,

Where should I place the read.delim(), before or after the read.table? Or is it instead of it?

I really appreciated the help! Back to study now!

Yes I should. After I posted the reply I started to search about it and found exactly the page you posted!

Feel so silly right now....

Thanks again for the help.

Don't worry about it, we're all learners here.

help(read.delim)

Log in to answer this question.