Results for "Extract"

Tags

  • perl -nle 'if (/^>/) { $sl = 0; print; next } next if ($sl >= 200); $_ = substr($_, 0, 200-$sl) if ($sl + length($_) > 200); $sl += length($_); print;' file.fa >new.fa #Perl #Extract #Fasta

    Tags: Perl, Extract, Fasta

    1146 days ago

  • Extract list of read ID from bam file: samtools view mbi.sorted.bam |perl -ne '/ID/ && print' > extractedID.sam #Extract #Ids #SAM #BAM #NGS

    Tags: Extract, Ids, SAM, BAM, NGS

    1160 days ago

  • Extract sequences by their ID from a fasta file. perl -ne 'if(/^>(\S+)/){$c=$i{$1}}$c?print:chomp;$i{$_}=1 if @ARGV' ids.txt sample1.fa #Extract #Sequences #IDs #Fasta #Perl #Trick #Oneliner

    Tags: Extract, Sequences, IDs, Fasta, Perl, Trick, Oneliner

    685 days ago

  • #Extract all #Reads from #BAM file for a #region Chr10:18000-45500 using #samtools: samtools view input.bam "Chr10:18000-45500" > output.bam

    Tags: Extract, Reads, BAM, region, samtools

    397 days ago

  • #Extract #tabbed info from #BAM file with samtools: samtools view test.bam|awk '{print $1 "\t" $2 "\t" $3 "\t" $4 "\t" $4+length($10)-1}' > file.xls

    Tags: Extract, tabbed, BAM

    398 days ago

  • #Extract #Chromosome #Number And Start Position #Reads: samtools view bamfile.bam|awk '{print $3 "\t" $4 "\t" $4+length($10)-1}' > newfile.tab

    Tags: Extract, Chromosome, Number, Reads

    391 days ago

  • Extract fasta sequence by Ids: perl -ne 'if(/^>(\S+)/){$c=grep{/^$1$/}qw(id1 id2)}print if $c' fasta.file #Perl #PerlOneliner #PerlTrick #Extract #Ids #Fasta

    Tags: Perl, PerlOneliner, PerlTrick, Extract, Ids, Fasta

    313 days ago

  • Extract sequence by using Ids file (assuming one ids in a line): perl -ne 'if(/^>(\S+)/){$c=$i{$1}}$c?print:chomp;$i{$_}=1 if @ARGV' ids.file fasta.file #PerlTricks #PerlOneliner #Perl #Extract #Ids #

    Tags: PerlTricks, PerlOneliner, Perl, Extract, Ids

    313 days ago

  • Extract a fasta sequence from multifasta file: samtools faidx multitest.fa and then samtools faidx multitest.fa fasta_id > out.fa #Samtools #Fasta #Extract #Multifasta

    Tags: Samtools, Fasta, Extract, Multifasta

    273 days ago

  • #Extract a #sequence from #multi-fasta file: $ perl -ne 'if(/^>(\S+)/){$c=grep{/^$1$/}qw(id1 id2)}print if $c' fasta.file

    Tags: Extract, sequence, multi

    135 days ago