Count the frequency of base G in a given DNA sequence
...tialize $countG and $currentPos my $countG = 0; my $currentPos = 0; #calculate the length of $DNA my $DNAlength = length($DNA); #for each letter in the sequence check if it i...2909 days ago
Genetic Algorithms demonstration with word DNA in Perl
...ng point my $dna_length = 512; # 4 "letters" in the DNA my $dna_byte_le...# eliminate words over $max_entry_length letters, and uppercase them @dic...return $sample; } # ASCII-centric byte to letter conversion sub byte_to_lette...2363 days ago
Perl script to delete the adjacent repeats !
...ore case when comparing, you could use: $string =~ s/(.)\1/$1/gi #And finally, if you wanted to trim any number of duplicates down to a single letter, this would work: $string...1542 days ago