Transpose the file coordinates and plot dendrogram in R
#Save this as tr.awk { for (i=1; i2645 days ago
Genetic Algorithms demonstration with word DNA in Perl
#!/usr/bin/perl -w # GA demonstration with word DNA (512 bits) use strict; use Data::Dumper; # individuals in the population my $popsize = 1024; # a good...2400 days ago
Extract fasta sequence with Ids with Bash script
#!/bin/bash while IFS='' read -r line || [[ -n "$line" ]]; do echo "Text read from file: $line" samtools faidx ONT.fasta $line > $line.faa done < "$1"2382 days ago
Reformat the file names with Perl
...= glob "*.scf"; if (!$ARGV[0]){ print "Table file needed\n USAGE: $0 table\n"; exit;} my $ifh = read_fh($ARGV[0]); while (my $line = ) { next if $line =~ /^#/; #next if $. ==...2364 days ago
Create genome scaffolding with Perl
...=s', 'pid=i', 'trimlimit=i', 'prefix=s'); # process remaining command line arguments (hopefully only PSL...sage({-exitVal => 1, -message => "Error: Unknown command-line option or ". "n...2336 days ago
Remove the duplicated line present only next to each other with Perl
...sr/bin/perl use strict; use warnings; { $_ = ; my $next_line; while( $next_line = ) { #print "curren...line: $_ -- next line: $next_line$/"; print $_ if $_ ne $next_line; } continue { $...2321 days ago
Extract the values between to user defined string with Perl
...cess_record() if /^\s*START/; } sub process_record { my $line; while (defined ($line = ) and $line !~ /^\s*END/)...} __DATA__ XXXX YYYY START These are the first set of lines which are to be extracted...2321 days ago
2292 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/Tutorial/Genome_estimation/sample_read_1.fastq /common/Tutorial/Genome_estimation/sample_rea...2274 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.fa'; my $fastaSeq_ref = readfasta ("$ARGV[0]"); my %fastaSeq...2249 days ago