Perl script to insert the DNA string in genome
#!/usr/bin/perl use warnings; use strict; use Bio::SeqIO; use Bio::Seq; my $file = $ARGV[0]; # in...osition of the insertion my $seqI = "AAAA"; #sequence of the i...ile => ">".$out); while( my $seq = $seq_in->next_seq() ) {...; } else{ $seq_out->write_seq($seq); }...2657 days ago
Calculate ATGC percentage in parallel with perl
...allel::ForkManager; use Bio::SeqIO; #usage: perl testParallel.pl my %sequences; my $seqio = Bio::SeqI...format => "fasta"); while(my$seqobj = $seqio->next_seq) {...ocs = 5; my @names = keys %sequences; # hash to resolve...{ my $name=shift; my $DNA=$sequences{$name}; my $length=len...2654 days ago
BASH script for SelfBLAST a genome
#!/bin/bash #self BLAST a genome -- Expec...MYDB=myDB OUTFILE=seeRES THREAD=20 SEQ="" echo "User $USER provid...; makeblastdb -in $FASTAFILE -parse_seqids -dbtype nucl -out $MYDB f..."all" ] then echo "You want entire sequence to blast" SEQ=$FASTAF...2650 days ago
Calculate some statistics for a DNA alignment with Perl
use Bio::AlignIO; use Bio::Align::DNAStatistics;...test.aln'); my $alnobj = $in->next_aln; my ($seq1id,$seq2id) = map { $_->display_id }...0); for (sort keys %$result3 ){ next if /Seq/; printf("%-9s %.4f \n...2647 days ago
Extracting FASTA sequences based on position with perl script !!
#!/usr/bin/env perl #Uses: perl sub-seq.pl input.txt range use strict; use warni...my ($header) = "$/$1_$start-$end\n"; my $seq = ${^POSTMATCH}; $seq =~.../g; print $header; print +( substr $seq, $start - 1, $end ) . "\n";...2620 days ago
Palindrome Simulation commands !
(base) ➜ palindromeAssemblySim more allCommands 3315 mutate.sh in= mutant15CH10...ndromeSimulated.fa -p -l 250 -f 100 -m 300 -s 10 -o paired_dat 3321 ~/Tools/seqtk/seqtk mergepe paired_dat1.fq pair...1733 days ago
Extract fasta sequence from a multifasta file with coordinates
#!/usr/bin/perl use Bio::DB::Fasta;...foreach my $id (@ids) { my $sequence = $db->seq($id, $querySizeST => $querySi...ary_ids; # Simple access my $seqstr = $db->seq('CHROMOSOME_I...m; while (my $seq = $stream->next_seq) { # Bio::PrimarySeqI st...2530 days ago
Calculate Dinucleotide Frequency with Perl
#!/usr/bin/perl -w use strict; my ($genome, $head, $tail); my (%mono_nt, %di_nt); $/ = ">"; open my $fasta, '2336 days ago
Extract the fastq sequence with range in Perl
use Bio::DB::Fasta; open(POSITIONS,"positions.txt"); while(){ chomp; my ($seqName,$begin,$end) = split(/\s/); my $db = Bio::DB::Fasta->new('allGenomeContacted.fa'); my $seq = $db->seq("$seqName", $begin => $end); print "$seq\n"; } close(POSITIONS);2466 days ago
Convert newline formated sequence into fasta format with perl
use strict; use warnings; my $filename = $ARGV[0]; open(my $fh, '2368 days ago