#!/bin/sh export LD_LIBRARY_PATH=/usr/local/apps/jellyfish-2.2.3/lib KMER=21 THREADS=20 BASE=${1%%.*} echo "File name base: $BASE" echo "Running jellyfish..." jellyfish count -s 1G -m ${KMER} -t ${THREADS} -o kmer -C $1 jellyfish dump -c -t kmer > ${BASE}.kmer${KMER}.txt echo "Preparing histogram..." awk '{print $2}' ${BASE}.kmer${KMER}.txt | sort -n | uniq -c | awk '{print $2 "," $1}' > ${BASE}.jf.hist