Perl script to extract lines with matching ids !!
#!/usr/bin/perl use strict; use warnings; my %patterns; #USAGE: perl extactByIds.pl Idsfile1 file2 > Result # Open file and get patterns to search for open(my $fh2,"2884 days ago
Converting from Windows-style to UNIX-style line endings with dos2unix
Lenovo-ideapad-320-15ISK:~/Downloads/abc/bin$ sudo apt install dos2unix [sudo] password for bioqu...kB in 3s (130 kB/s) Selecting previously unselected package dos2unix. (Reading database...1186 days ago
Perl subroutine to read and write files
# Input output (InOut) the file # usage: # @array = InOut('read',...rite','file.txt',\$string); sub InOut { my($bit,$file,$data) = @_;...annot open $file for output: $!\n"; print InOut ref $data eq...2875 days ago
Blast script to index and extract sequence !!
# look at the file $ head EC4115.fa >NC_011353.1 Escherichia coli...CATAGCGCACAGACAGATAAAAATTACAGAGTAC # generate the blast database $ ma...ACTTTAACCAATATAGGCATAGCGCACAGAC .... # query the blast database...2861 days ago
Install ATOM editor on Elemantory OS / Ubuntu
#Download ATOM deb file from https://atom.io/ https://atom.io/download/deb (base) bioqueen@bio...in 4s (219 kB/s) Selecting previously unselected package gconf2-common. (Reading database...1185 days ago
2702 days ago
BASH script for SelfBLAST a genome
#!/bin/bash #self BLAST a genome -- Expecting you have blast and samtools installed in your sys...arguments, Detail of the arguments: $@" if [ -f $MYDB.nhr ] then echo "BLAST database...2661 days ago
Calculate some statistics for a DNA alignment with Perl
use Bio::AlignIO; use Bio::Align::DNAStatistics; my $stats =...'emboss', -file => 't/data/insulin.w...mat => 'fasta', -file => 't/data/nei...2658 days ago
Extract fasta sequence from a multifasta file with coordinates
#!/usr/bin/perl use Bio::DB::Fasta; #USAGE perl extractFASTAwithSIZE.pl finalSample_filtere...print ">$id\n", "$sequence\n"; } __END__ use Bio::DB::Fasta; # Create database...2541 days ago
Read a tab delimited file and search with perl
use strict; use warnings; use Data::Dumper; use Text::CSV; use IO::Handle; my $file = "/home/urbe/Tools/Alienomics_v0.1/Alienomics/output/intermediate_files/rRNA/refGene.megablast"; open my $fh, "[0]\n"; warn Dumper $row; # To see the structure }2534 days ago