[Bioc-sig-seq] who have RNA-seq pipeline code

Steve Lianoglou mailinglist.honeypot at gmail.com
Tue Sep 6 05:09:07 CEST 2011


Hi,

On Mon, Sep 5, 2011 at 10:22 PM, wang peter <wng.peter at gmail.com> wrote:
> by the way
> * Quality assessment
> Use ShortRead to produce a basic QA report. Down-sample fastq files if
> they are big.
>  library(ShortRead)
>  fls <- list.files(fastqDir, "fastq$", full=TRUE)
>  names(fls) <- sub(".fastq", "", basename(fls))
>  ## use FastqSampler if fastq files are large
>  qas <- lapply(seq_along(fls),
>               function(i, fls) qa(readFastq(fls[i]), names(fls)[i]),
>               fls)
>  qa <- do.call(rbind, qas)
>  save(qa, file=file.path(outputDir, "qa.rda")
>  browseURL(report(qa))
>
> in the line of qas, i means the ith file. do u need write a loop to assign i

lapply *is* the loop.

See ?lapply and ?seq_along

Please don't take this the wrong way, but if you feel like you don't
really have a good grip on R basics, investing some time to read up on
them will really make your life a lot easier ... especially when doing
some of the more complicated things that you want to tackle.

-steve

> thx
> shan gao
>
>        [[alternative HTML version deleted]]
>
> _______________________________________________
> Bioc-sig-sequencing mailing list
> Bioc-sig-sequencing at r-project.org
> https://stat.ethz.ch/mailman/listinfo/bioc-sig-sequencing
>



-- 
Steve Lianoglou
Graduate Student: Computational Systems Biology
 | Memorial Sloan-Kettering Cancer Center
 | Weill Medical College of Cornell University
Contact Info: http://cbio.mskcc.org/~lianos/contact



More information about the Bioc-sig-sequencing mailing list