Extract a random sequence from a file
#!/usr/local/bin/perl -w use strict; use warnings; use...t.txt'; open my $in_fh, '', $outputfile; my $size = 21; my $count =...my @start_points = shuffle(0 .. $len_genome-$size); next unless @start_poin...2905 days ago
2900 days ago
Perl script to extract fasta sequence by matching name/ids !!
#!/usr/bin/perl use strict; use warnings; use Text::Trim qw(trim); #U...; my @ids=split (/\t/, $_); $select{$ids[0]} = 1; } my $size = keys %select; print "Total Ids $size\n"; close LINE; $/ = "\n>...2865 days ago
Perl script introduces control structures, arrays and hashes.
#!/usr/bin/env perl use strict; use warnings; my...irst_array[0], "\n\n"; # Scalar gives actual size of an array my $size_of_array = scalar(@first_arra...rray: $size_of_array\n\n"; print "Perl's index size of array: $#first_array\n\n";...2852 days ago
2683 days ago
Genetic Algorithms demonstration with word DNA in Perl
#!/usr/bin/perl -w # GA demonstration...ulation = shift @_; my $pop_size = scalar @$population; # p...in trouble die "Population size $pop_size is too small" if $p...rent_population[int(rand($pop_size))]; my $child = { survived...ref; printf "generation %d: size %dnleast fit DNA [%s]/%d\n...2362 days ago
2254 days ago
Plot custom gene density with R
library(karyoploteR) pp2240 days ago
Estimate Genome Size with Jellyfish and R
jellyfish count -t 8 -C -m 19 -s 5G -o 19mer_out --min-qual-char=? /common/Tutori...th strands #-m -mer-len=unit32 Length of the k-mer #-s -size=unit32 Hash size / memory allocation #-o...2236 days ago
Perl script to run SATSUMA in loop !
#!/usr/bin/perl -w use strict; use File::Temp qw(tempfile); # Usage pe...be/Tools/SATSUMA/satsuma-code-0"; # Location of ur SATSUMA my $maxSize = 5000; my $resolution = 5000; my $dotsize = 1; my $cpu=40; my @ids;...2130 days ago