User Tools

Site Tools


myillu_01.trimpe.sh

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
myillu_01.trimpe.sh [2016/05/07 13:00]
hyjeong
myillu_01.trimpe.sh [2016/12/06 09:56] (current)
hyjeong
Line 6: Line 6:
   # Trimmomatic v0.32 manual: ​   # Trimmomatic v0.32 manual: ​
   #   ​http://​www.usadellab.org/​cms/​uploads/​supplementary/​Trimmomatic/​TrimmomaticManual_V0.32.pdf   #   ​http://​www.usadellab.org/​cms/​uploads/​supplementary/​Trimmomatic/​TrimmomaticManual_V0.32.pdf
 +  #
 +  # Latest version of ngopt (a5_miseq): 20150522
   ​   ​
   TRIMMOMATIC=/​usr/​local/​apps/​a5_miseq_linux_20140604/​bin/​trimmomatic.jar   TRIMMOMATIC=/​usr/​local/​apps/​a5_miseq_linux_20140604/​bin/​trimmomatic.jar
Line 12: Line 14:
   THREADS=24   THREADS=24
   MINLEN=75   MINLEN=75
 +  # default MINLENG is 75 (for NGOPT, 36 bp)
   ​   ​
   if [ $# -ne 2 ]   if [ $# -ne 2 ]
Line 27: Line 30:
   done   done
   ​   ​
-  ​+  ​# Using `basename` command is a good idea. Because the stripped BASE 
 +  # can be used as a output file prefix in "​current"​ directory.
   BASE=$(basename "​$1"​) ​ # delete any leading path   BASE=$(basename "​$1"​) ​ # delete any leading path
   BASE=${BASE%_*} ​          # delete string from '​_'​ to the end (shortest match)   BASE=${BASE%_*} ​          # delete string from '​_'​ to the end (shortest match)
-  # BASE=${1%%_*} makes difference. What is it?  +  # BASE=${1%%_*} makes difference. What is it? (longest match) 
-  # BASE=${1/​_*/​}+  # BASE=${1/​_*/​} ​(longest match)
   echo "File name base: $BASE"   echo "File name base: $BASE"
 +  BASE=${BASE}-trim
 +  echo "File name base will be changed into ${BASE}"​
   ​   ​
   java -jar $TRIMMOMATIC PE -threads ${THREADS} -phred33 -baseout ${BASE}.fq.gz $1 $2 ILLUMINACLIP:​$ADAPTER:​2:​30:​10 LEADING:3 TRAILING:3 SLIDINGWINDOW:​4:​20 MINLEN:​${MINLEN}   java -jar $TRIMMOMATIC PE -threads ${THREADS} -phred33 -baseout ${BASE}.fq.gz $1 $2 ILLUMINACLIP:​$ADAPTER:​2:​30:​10 LEADING:3 TRAILING:3 SLIDINGWINDOW:​4:​20 MINLEN:​${MINLEN}
myillu_01.trimpe.sh.txt · Last modified: 2016/12/06 09:56 by hyjeong