This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ps -axeo pid,etime,command | awk '$2~/^0[1234]-/ && $0~/COMMAND/ { print $1 }' | xargs kill |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for FILE in *.tsv; do | |
LI=`grep -v '^#' $FILE | wc -l`; | |
SEQS=`gunzip -c ./../NPRB/$F1.faa.gz | grep -c '^>'`; | |
BP=`gunzip -c ./../NPRB/$F1.faa.gz | grep -v '^>' | wc -b`; | |
echo -e "$FILE\t$LI" >> target_hits.txt; | |
done | |
rm target_hits2.txt; | |
for FILE in *.tsv; do |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
Search=$1 | |
grep -i $Search FOAM-onto_rel1.tsv > $Search.ont | |
grep -i $Search FOAM-onto_rel1.tsv | cut -f5 > $Search.ko | |
wc -l $Search.ko | |
rm $Search.acc | |
grep -A1 -f $Search.ko ./../FOAM/FOAM-hmm_rel1a_switch.hmm | grep NAME | tr -s ' ' | cut -f2 -d' ' | sort -u > $Search.acc | |
wc -l $Search.acc |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
head -n1000 18*R1.fastq | grep -v -e '==> 18' -e '^$' | paste - - - - | cut -f2 | sort | uniq -c | sort -rn | head -n1000 | catg > 18s-top1000f.fa |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
NODE=bio | |
THREADS=7 #7 for bio, 24 for t1small | |
MEM=200 #128 max for t1small, 200+ for bio | |
mkdir -p spades-assembly | |
DIR='.' | |
#NPRB_meta_TBS.04.MEIO.R1.trimmed.fastq.gz | |
for PREFIX in `ls *.trimmed.fastq.gz | cut -f1-3 -d'.' | sort -u `; do |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# run hmmer using hmm files | |
#INDIR=$1 #directory to search for .fastq.gz files | |
INDIR=~/work/NPRB | |
cd ~/work/hmm | |
for hmmfile in *.hmm; do | |
hmm=`basename $hmmfile .hmm`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
while read line; do curl -s "https ://api.crossref.org/works?query=`echo $line | tr -sC '[^a-zA-Z]' '+'`" | tr "," "\n" | tr -d '"\' | grep ^DOI | cut -f2- -d':' | head -n1 | xargs -I{} curl -sLH "Accept: application/x-bibtex" https ://doi.org/{} | grep -v '^\s*[<"]'; done < file |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
while read line; do curl -LH "Accept: application/x-bibtex" https://doi.org/$line | grep -v '^\s*[<"]'; done < dois.txt > dois.bib |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
while read line; do title=`echo $line | sed 's/ /+/g'`; curl -s https://api.crossref.org/works?query.title=$title&rows=1 | tr ',' '\n' | tr -d '"\' | grep ^DOI | cut -f2- -d':'; done < titles.txt > titles.bib |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Q&A |
NewerOlder