Perl onliner to check the ids in two files !
perl -lane 'BEGIN{open(A,"ids2.txt"); while(){chomp; $k{$_}++}} if (defined($k{$F[0]})) {print "$_\t$F[0]\t1"} else {print "$_\tNA\t0"}; ' ids1.txt > aaa.xls979 days ago
Installing Covid19 Environment !
(base) vikas@vikas-Lenovo-ideapad-320-15ISK:~/vinodLab/Genepi$ conda env create -f cov...########################################## | 100% perl-xml-parser-2.44 | 165 KB |...########################################## | 100% perl-gd...975 days ago
Run Pango on your multifasta file !
#More at https://cov-lineages.org/resources/pangolin/usage.html (base) [jnarayan...your own risk. For more info please refer to: https://scikit-learn.org/stable/modules/model_persistence.html#securi...939 days ago
Perl script to rename the fasta file !
#Script #1 #!/usr/bin/perl -w use strict; #USAGE #perl extractPattern.pl kmerfasta > uniref100_result_broad my %kHash; local $/ = '>'; my $infile2 = "$ARGV[0]"; # Kmer fasta open( FH2, '910 days ago
Extract all fasta sequences except ids !
awk 'BEGIN{while((getline0)l[">"$1]=1}/^>/{f=!l[$1]}f' genomic.fna > filtered_without_omi.fasta #extract subse...9.fa out=omi_kmer19_formated.fa fastawrap=19 #Extract and number the kmers perl st...880 days ago
bash script to extract sequence by ids !
Use a Perl one-liner, grep and seqtk subseq to extract the desired fasta sequences: # Create test input: cat > in.fasta BGI_novel_T016313 Solyc03g025570.2.1 TTCA...875 days ago
Commands to get the detail of disk usage on Linux !
#A simplistic approach would be du -shc /home/* du -shc /home/jnarayan #To sort it: du -smc /home/* | sort -n #There is also a wellknown Perl script that has the option of mailing disk usage reports per user: durep http://www.ubuntugeek.com/create-disk-usage-reports-with-durep.html868 days ago
Command line to print disk usage on Linux terminal !
#Print disk usage - perl du -h |perl -e'%h=map{/.\s/;99**(ord$&&7)-$`,$_}`du -h`;die@h{sort%h}' #Bash du -k * | sort -nr | cut -f2 | xargs -d '\n' du -sh #Base du -scBM | sort -n #More du -s * | sort -rn | cut -f2- | xargs -d "\n" du -sh867 days ago
Multiline fasta to single line fasta !
perl -pe '$. > 1 and /^>/ ? print "\n" : chomp' in.fasta > out.fasta847 days ago
837 days ago