JASREET HUNDAL <[email protected]> writes: > I am new to R and don't quiet understand this correctly. When I tried > ?writeFastq , nothing is displayed. > Is there is any other way to export the trimmed reads? I am using this > workflow: > http://www.bioconductor.org/help/workflows/high-throughput-sequencing/
Hi Jess -- what is the output of > sessionInfo() ? Hopefully you're using R 2.11.0 or more recent, and ShortRead 1.6.0 or better. If not, update your R or (if your R is current but not ShortRead) installed packages as outlined at http://bioconductor.org/install/index.html#update-bioconductor-packages In the workflow you mention, it should be as easy as writeFastq(trimmed, "/path/to/file") It is a little more convoluted for fasta output fa <- sread(trimmed) names(fa) <- id(trimmed) write.XStringSet(fa, "/path/to/file") It can help to try to convey what you mean by 'nothing seems to be working' by copying and pasting a part of your R session into your email, especially if the snippet is reproducible (e.g., previously running example(readFastq), and using the 'rfq' object that is created as the data you're trying to write to a file). Also, if things just seem to hang, then maybe you could confirm that you have the 'right idea' by trying to write a subset of the data, e.g., writeFastq(trimmed[1:10] Martin > Thanks! > > > On Mon, Aug 16, 2010 at 5:50 PM, Marcus Davy <[email protected]> wrote: > >> One option is to try writeFastq to fastq format, I believe it was working >> on recently and is fast. >> >> exptPath <- system.file("extdata", package = "ShortRead") >> sp <- SolexaPath(exptPath) >> fqpattern <- "s_1_sequence.txt" >> fl <- file.path(analysisPath(sp), fqpattern) >> fq <- readFastq(sp, fqpattern) >> >> tf <- tempfile(tmpdir="/tmp") >> >> writeFastq(fq, tf) >> >> >> Marcus >> >> >> On Tue, Aug 17, 2010 at 10:42 AM, JASREET HUNDAL <[email protected]>wrote: >> >>> Has anyone worked with trimLRPatterns function in the ShortRead library >>> for >>> adaptor trimming? >>> What is the best way to export the trimmed reads in a fasta/fastq/text >>> file? >>> I have a large 5,000,000 line fastq file with 50bp reads as input. >>> I have tried write.table as well as writeFASTA but nothing seems to be >>> working. >>> Hence, I would appreciate if somebody could help me out as I am novice in >>> the world of R/Bioconductor. >>> >>> Thanks >>> -Jess >>> >>> [[alternative HTML version deleted]] >>> >>> _______________________________________________ >>> Bioc-sig-sequencing mailing list >>> [email protected] >>> https://stat.ethz.ch/mailman/listinfo/bioc-sig-sequencing >>> >> >> > > [[alternative HTML version deleted]] > > _______________________________________________ > Bioc-sig-sequencing mailing list > [email protected] > https://stat.ethz.ch/mailman/listinfo/bioc-sig-sequencing -- Martin Morgan Computational Biology / Fred Hutchinson Cancer Research Center 1100 Fairview Ave. N. PO Box 19024 Seattle, WA 98109 Location: Arnold Building M1 B861 Phone: (206) 667-2793 _______________________________________________ Bioc-sig-sequencing mailing list [email protected] https://stat.ethz.ch/mailman/listinfo/bioc-sig-sequencing
