Mercurial > repos > davidvanzessen > baseline_bayesian_estimation
comparison wrapper.sh @ 0:d685e7ba0ed4 draft
Uploaded
author | davidvanzessen |
---|---|
date | Tue, 15 Jul 2014 08:43:49 -0400 |
parents | |
children | e8dd8474aecb |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:d685e7ba0ed4 |
---|---|
1 #!/bin/bash | |
2 dir="$(cd "$(dirname "$0")" && pwd)" | |
3 | |
4 testID=$1 | |
5 species=$2 | |
6 substitutionModel=$3 | |
7 mutabilityModel=$4 | |
8 clonal=$5 | |
9 fixIndels=$6 | |
10 region=$7 | |
11 input=$8 | |
12 outDir=$9 | |
13 #mkdir $outDir | |
14 outID=${10} | |
15 outFile=${11} | |
16 outFile2=${12} | |
17 | |
18 cd $dir | |
19 Rscript --verbose $dir/Baseline_Main.r $testID $species $substitutionModel $mutabilityModel $clonal $fixIndels $region $input $dir/ $outID 2> /dev/null | |
20 | |
21 mv $dir/${outID}.txt $outFile | |
22 mv $dir/${outID}.RData $outFile2 | |
23 | |
24 #tail -n+2 $outDir/${outID}.txt > $outDir/tmp.txt | |
25 #echo "<html><table border='1'><thead>" >> $outFile | |
26 #echo "<tr><th>Type</th><th>ID</th><th>Observed_CDR_R</th><th>Observed_CDR_S</th><th>Observed_FWR_R</th><th>Observed_FWR_S</th><th>Expected_CDR_R</th><th>Expected_CDR_S</th><th>Expected_FWR_R</th><th>Expected_FWR_S</th><th>Focused_Sigma_CDR</th><th>Focused_CIlower_CDR</th><th>Focused_CIupper_CDR</th><th>Focused_Sigma_FWR</th><th>Focused_CIlower_FWR</th><th>Focused_CIupper_FWR</th><th>Focused_P_CDR</th><th>Focused_P_FWR</th></tr></thead><tbody>" >> $outFile | |
27 #while read Type ID Observed_CDR_R Observed_CDR_S Observed_FWR_R Observed_FWR_S Expected_CDR_R Expected_CDR_S Expected_FWR_R Expected_FWR_S Focused_Sigma_CDR Focused_CIlower_CDR Focused_CIupper_CDR Focused_Sigma_FWR Focused_CIlower_FWR Focused_CIupper_FWR Focused_P_CDR Focused_P_FWR | |
28 #do | |
29 # echo "<tr><td>$Type</td><td>$ID</td><td>$Observed_CDR_R</td><td>$Observed_CDR_S</td><td>$Observed_FWR_R</td><td>$Observed_FWR_S</td><td>$Expected_CDR_R</td><td>$Expected_CDR_S</td><td>$Expected_FWR_R</td><td>$Expected_FWR_S</td><td>$Focused_Sigma_CDR</td><td>$Focused_CIlower_CDR</td><td>$Focused_CIupper_CDR</td><td>$Focused_Sigma_FWR</td><td>$Focused_CIlower_FWR</td><td>$Focused_CIupper_FWR</td><td>$Focused_P_CDR</td><td>$Focused_P_FWR</td></tr>" >> $outFile | |
30 #done < $outDir/tmp.txt | |
31 #echo "</tbody></table></html>" >> $outFile | |
32 #rm $outDir/tmp.txt | |
33 |