-
Notifications
You must be signed in to change notification settings - Fork 0
/
trim_trimmomatic_SE_v1.pl
47 lines (31 loc) · 1.04 KB
/
trim_trimmomatic_SE_v1.pl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#######################################################
#
# Script name: trim_trimmomatic_SE_v1
# Language: Perl
# Program: Trimmomatic
# Purpose: Trim single end RNA-seq data
# Author: Arindam Ghosh
# Date: 4 September 2019
#
#######################################################
#!/usr/bin/perl
use Cwd;
$cwd = getcwd;
open (FH, "/home/dell/Documents/Arindam/WorkB/PRJEB4879/PRJEB4879.txt");
@file = <FH>;
close FH;
for($i=1; $i<@file; $i++)
{
@col = split(/\t/, "$file[$i]");
mkdir $col[1];
chdir "$cwd/$col[1]";
#TRIMMING USING TRIMMOMATIC
print "\nTRIMMING $col[1]\n";
$trim_cmd = "java -jar ~/Documents/Softwares/Trimmomatic/Trimmomatic-0.36/trimmomatic-0.36.jar SE -trimlog $col[1]_trim.log /home/dell/Documents/Arindam/WorkB/PRJEB4879/RawRead/$col[1]/$col[1].fastq.gz $col[1]_clean.fq.gz ILLUMINACLIP:/home/dell/Documents/Softwares/Trimmomatic/Trimmomatic-0.36/adapters/TruSeq3-SE.fa:2:30:10 TRAILING:20 MINLEN:60";
system ($trim_cmd);
system ("fastqc *.gz");
open (FP, '>', 'trim_cmd.txt');
print FP $trim_cmd;
close FP;
chdir $cwd;
};