Reformat the file names with Perl
#!/usr/bin/perl use strict; use warnings; use File::Copy qw(copy);; $| = 1; my %hash; my @files = glob "...sub read_fh { my $filename = shift @_; my $filehandle; open $...2331 days ago
Convert fastq to fasta in Perl
use Bio::SeqIO; #convert .fastq.gz to .fasta open my $zcat, 'zcat seq.fastq.gz |' or die $!; my $in=Bio::SeqIO->new(-fh=>$zcat, -format=>'fastq');...2326 days ago
Insert the sequence at desire location in multi-fasta file with Perl
#!/usr/bin/perl use warnings; use strict; use Bio::SeqIO; use Bio::Seq; use File::Copy; #ARGV[0] should...hould not overlaps --- next postition shold be bigger than firstpos+alienLen open(m...2309 days ago
Create genome scaffolding with Perl
#!/usr/bin/perl use warnings; use strict; use English; use Pod::Usage; ## uses pod documentation in usage...-verbose => 0}); } print(STDERR "Loading query sequences into memory..."); open(m...2303 days ago
Plot the clock using Lastz -gerenal outfile
use strict; use warnings; use Statistics::R ; use List::Util qw(sum); #Usage perl clockPlot.pl P...->new() ; $R->startR ; my $fileN=$ARGV[0]; my $mSize=$ARGV[1]; open (my $fh2, $fileN) or die "Could not open f...2294 days ago
Remove duplicate lines with perl
#! perl -sw use strict; my %lines; #open DATA, $ARGV[0] or die "Couldn't open $ARGV[0]: $!\n"; while () { print if not $lines{$_}++; } __DATA__ apple apple plum vinegar apple banana banana banana apple2288 days ago
845 days ago
Plot custom gene density with R
library(karyoploteR) pp2245 days ago
Perl script to read multi fasta sequence one by one
#!/usr/bin/env perl use strict; use warnings; #USAGE #perl rohanRun.pl seq.fa my $outfile='tmp...my %fastaSeq = %$fastaSeq_ref; foreach my $key ( keys %fastaSeq) { open (OUT, ">$outfile") or die "couldn't open t...2216 days ago
Perl script to extract the uniq Ids
#!/usr/bin/perl -w use strict; use warnings; use List::Uniq ':all'; open(my $val, "2234 days ago