added shell script to format muts for mcsm NA
This commit is contained in:
parent
a6f1f65acf
commit
84970a667c
5 changed files with 54 additions and 31 deletions
19
mcsm_na/split_format_csv.sh
Executable file
19
mcsm_na/split_format_csv.sh
Executable file
|
@ -0,0 +1,19 @@
|
|||
#!/bin/bash
|
||||
|
||||
# FIXME: This is written for expediency to kickstart running dynamut and mcsm-NA
|
||||
|
||||
# Usage: ~/git/LSHTM_analysis/dynamut/split_csv.sh <input file> <output dir> <chunk size in lines>
|
||||
# copy your snp file to split into the mcsm_na dir
|
||||
|
||||
INFILE=$1
|
||||
OUTDIR=$2
|
||||
CHUNK=$3
|
||||
|
||||
mkdir -p ${OUTDIR}/${CHUNK}
|
||||
cd ${OUTDIR}/${CHUNK}
|
||||
|
||||
split ../../${INFILE} -l ${CHUNK} -d snp_batch_
|
||||
for i in *; do mv $i $i.txt; done
|
||||
sed -i 's/^/A /g' *.txt
|
||||
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue