[BioC] Limma Package to read cDNA data
Joyce Gu
jwgu at bcm.tmc.edu
Fri Mar 5 16:28:36 MET 2004
Hi,
I did have my file in R environment, first I use this command to get my file
into my current directory,
> file<-dir(path="D:/BioconductorProject/OScaseAnalysis",pattern="*.txt")
and I check it is there,
> file
[1] "os677AT.txt"
then I used the following command to read my data into R
RG<-read.maimages(file,columns=list(Rf="Ch2 Median",Rb="Ch2 B Median",Gf="Ch1
Median",Gb=" Ch1 B Median"))
Unfortunately, I got the following error message,
Error in file(con, "r") : unable to open connection
In addition: Warning message:
cannot open file `os677AT.txt'
The file os677AT.txt is there, why they still can not find them.
Thanks
>===== Original Message From Gordon Smyth <smyth at wehi.edu.au> =====
>At 08:45 AM 5/03/2004, Joyce Gu wrote:
>>I tried the command to read my .txt file into R for limma analysis,
>
>What command, exactly?
>
>> but I got
>>the following error message:
>>
>>Error in file(con, "r") : unable to open connection
>>In addition: Warning message:
>>cannot open file `os677AT.txt'
>
>This means your data file doesn't exist. Type dir() and if you don't see
>the file, then neither can R. Did you type the name correctly? Do you need
>to specify a path? Do you need to set the working directory?
>
>Gordon
>
>>I could not figure out what's wrong?
>>Any suggestion is greatly appreciated!
>>
>> >===== Original Message From Matthew Ritchie <mritchie at wehi.edu.au> =====
>> >Hi Joyce,
>> >
>> >The function read.maimages() should be able to handle your custom format
>> >data. You can specify the columns you want to read in for the red
>> >foreground and background (Rf, Rb) and green foreground and background
>> >(Gf, Gb) using the 'columns' argument, which takes a list with
>> >components Rf="red foreground column name", Gf="green foreground column
>> >name", Rb="red background column name" and Gb="green background column
>> >name".
>> >
>> >For example, if I have 2 image analysis output files (array1.txt and
>> >array2.txt in tab delimited text format) in the current working
>> >directory, and I want the columns "F635 Mean" and "F532 Mean" for the
>> >red and green foregrounds and "B635 Median" and "B532 Median" for the
>> >red and green backgrounds, then the following commands:
>> >
>> >files <- dir(pattern=".txt")
>> >files
>> ># [1] "array1.txt" "array2.txt"
>> >RG <- read.maimages(files, columns=list(Rf="F635 Mean", Rb="B635
>> >Median", Gf="F532 Mean", Gb="B532 Median"))
>> >
>> >will read in the relevant columns and store them in an RGList object.
>> > Alternatively, if your image analysis data is from one of the packages
>> >Spot, GenePix, SMD, Imagene, Arrayvision or Quantarray, then you can
>> >specify this using the 'source' argument. The relevant columns (Rf, Rb,
>> >Gf and Gb) are extracted automatically when 'source' is specified. For
>> >example
>> >
>> >RG <- read.maimages(files, source="genepix")
>> >
>> >is equivalent to the previous call. For more information on this
>> >function, try
>> >
>> >?read.maimages
>> >
>> >or
>> >
>> >help.start()
>> >
>> >and take the 'Packages', 'limma' and '3.ReadingData' links.
>> >Best wishes,
>> >
>> >Matt Ritchie
More information about the Bioconductor
mailing list