Seqanswers Leaderboard Ad

Collapse

Announcement

Collapse
No announcement yet.
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • BBduk in process substitution or with named pipes?

    hello (brian),

    would it be possible to use bbduk as process substituion for mapping, like this.

    Code:
    mapper read1 <(bbduk.sh in1=R1.fastq.gz in2=R2.fastq.gz out1=stdout.fq out2=NULL ref=ref.fa.gz ktrim=r hdist=1) read2 <(bbduk.sh in1=R1.fastq.gz in2=R2.fastq.gz out1=NULL out2=stdout.fq ref=ref.fa.gz ktrim=r hdist=1)
    i do not want keep the trimmed fastq-files, but have to ensure pairdness. how can i repress the output of the each other read?

    or would it even work somehow with named pipes...
    Code:
    mkfifo pipe1.fq
    mkfifo pipe2.fq
    
    bbduk.sh in1=R1.fq.gz in2=R2.fq.gz out1=pipe1.fq out2=pipe2.fq ref=ref.fa.gz ktrim=r hdist=1
    
    mapper read1 <pipe1.fq read2 <pipe2.fq
    thank you,

    dietmar

  • #2
    to answer my own question: it works...

    it works as follows:

    mkfifo pipe1.fq
    mkfifo pipe2.fq

    bbduk.sh overwrite=true in1=R1_001.fastq.gz in2=R2_001.fastq.gz out1=pipe1.fq out2=pipe2.fq ref=truseq_rna.fa.gz ktrim=r hdist=1 &

    ( /home/ws/SW_install/bowtie/bowtie-1.1.1/bowtie -q -v 3 -3 0 -p 21 -a -m 100 --sam gencode19 -1 pipe1.fq -2 pipe2.fq | samtools view -Sb - > SID2158.bam ) 2> SID2158.log

    rm -f pipe1.fq
    rm -f pipe2.fq
    dietmar

    Comment


    • #3
      I'm glad you were able to answer that yourself, as I never use named pipes

      Comment


      • #4
        Doesn't bash process substitution use named pipes? It ends up that you're using them either way then, it's only a difference of 1 vs. 2 pipes.

        Comment


        • #5
          probably,

          but in the first case, bash uses (probably) named pipes internally, in the other case I set and use the named pipes (and i think this is meant with "named pipes" in bash)...

          Comment


          • #6
            @dietmar13: Since you have likely tested this already, does option 1 not work as written or it does?

            Comment


            • #7
              @GenoMax

              I didn't try 1 because 2 works. in 1 trimming will be made twice (would be a real waste of resources)...

              Comment

              Latest Articles

              Collapse

              • seqadmin
                Current Approaches to Protein Sequencing
                by seqadmin


                Proteins are often described as the workhorses of the cell, and identifying their sequences is key to understanding their role in biological processes and disease. Currently, the most common technique used to determine protein sequences is mass spectrometry. While still a valuable tool, mass spectrometry faces several limitations and requires a highly experienced scientist familiar with the equipment to operate it. Additionally, other proteomic methods, like affinity assays, are constrained...
                04-04-2024, 04:25 PM
              • seqadmin
                Strategies for Sequencing Challenging Samples
                by seqadmin


                Despite advancements in sequencing platforms and related sample preparation technologies, certain sample types continue to present significant challenges that can compromise sequencing results. Pedro Echave, Senior Manager of the Global Business Segment at Revvity, explained that the success of a sequencing experiment ultimately depends on the amount and integrity of the nucleic acid template (RNA or DNA) obtained from a sample. “The better the quality of the nucleic acid isolated...
                03-22-2024, 06:39 AM

              ad_right_rmr

              Collapse

              News

              Collapse

              Topics Statistics Last Post
              Started by seqadmin, 04-11-2024, 12:08 PM
              0 responses
              25 views
              0 likes
              Last Post seqadmin  
              Started by seqadmin, 04-10-2024, 10:19 PM
              0 responses
              29 views
              0 likes
              Last Post seqadmin  
              Started by seqadmin, 04-10-2024, 09:21 AM
              0 responses
              25 views
              0 likes
              Last Post seqadmin  
              Started by seqadmin, 04-04-2024, 09:00 AM
              0 responses
              52 views
              0 likes
              Last Post seqadmin  
              Working...
              X