Install BLAST in Ubuntu/Linux and Window !
#On ubuntu sudo apt-get install ncbi-blast+ #Ubuntu Conda installation conda install -c bioconda blast #Windows installation First: Download ftp:...-win64.exe with your web browser. #If that FTP links does not work, try...1162 days ago
2932 days ago
Count the frequency of base G in a given DNA sequence
#!/usr/bin/perl use strict; use warnings; my $DNA = "GATTACACAT"; #initialize $countG and $currentPos my $countG = 0; m...#calculate the length of $DNA my $DNAlength = length($DNA); #for...e = substr($DNA,$currentPos,1); if($base eq "G"){ $countG++; }...2932 days ago
2932 days ago
Read lines from input file – print lines that match a regular expression
#!/usr/bin/perl use strict; use warnings; my $line; #read the line-by-line for each line ask if it matches the regex print it if it matches while($line = ){ chomp $line; if ($line =~ /^ATG?C*[ATCG]+?A{3,10}$/) {...2932 days ago
Check if your coputer ready to use BioPerl
#!/usr/bin/perl use strict; use warnings; #bioperl example code use strict; use warnings; #make the bioperl module (class) accessible to your program use Bio::Seq; print"ok - ready to use Bio::Seq";2932 days ago
Parse a genbank file using regular expressions
#! /usr/local/bin/perl -w $genbank = "genbank_file.txt"; open (GENBANK, $genbank) || die "cannot open $gb_report for reading: $!"; # Flag for multi...)/) { print "Sequence name: $2\n"; } elsif (/(...else { # Skip this data } }...2932 days ago
BioPerl to convert between sequence formats from Fasta to Genbank
#!/usr/local/bin/perl -w # Sequence formats to choose: Fasta, EMBL. GenBank, Swissprot, PIR and GCG use Bio::SeqIO; $inFile = "BRCA2.fa"; $in = Bio::SeqIO->n...> 'Fasta'); $out = Bio::SeqIO->newFh('-format' => 'Genbank'); print $out...2931 days ago
2931 days ago
Perl script to Mutate a DNA Sequence
#!/usr/local/bin/perl -w # This script randomly mutates the DNA sequence and generates 10 suc...this script, enter the file name with its full path. # Exam...afilename) ) { print "Cannot open file \"$dnafilename\...(); } until ($newbase ne $current_base);...2931 days ago