Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
NGS CLIA Lab
process_scripts
Commits
96bcf788
Commit
96bcf788
authored
Aug 31, 2020
by
Brandi Cantarel
Browse files
se/pe fix
parent
68aac6f3
Changes
2
Hide whitespace changes
Inline
Side-by-side
alignment/rnaseqalign.sh
View file @
96bcf788
...
...
@@ -45,35 +45,43 @@ if [[ -z $NPROC ]]
then
NPROC
=
`
nproc
`
fi
fqs
=
''
i
=
0
numfq
=
${#
fqs
[@]
}
while
[[
$i
-le
$numfq
]]
do
fqs
=
"
$fqs
$1
"
i
=
$((
i
+
1
))
shift
1
done
hisat_opt
=
''
diff
$fq1
$fq2
>
difffile
if
[[
-f
$fq1
]]
then
fqs
=
"
$fq1
"
if
[[
-f
$fq2
]]
then
diff
$fq1
$fq2
>
difffile
if
[[
-s
difffile
]]
then
fqs+
=
"
$fq2
"
fi
fi
else
fqs
=
''
i
=
0
numfq
=
${#
fqs
[@]
}
while
[[
$i
-le
$numfq
]]
do
fqs
=
"
$fqs
$1
"
i
=
$((
i
+
1
))
shift
1
done
fi
if
[[
-f
$fq2
]]
&&
[[
-s
difffile
]]
then
fqs+
=
"
$fq2
"
fi
numfq
=
${#
fqs
[@]
}
numfq
=
0
for
k
in
$fqs
do
numfq
=
$((
numfq
+
1
))
done
hisat_opt
=
''
star_opt
=
$fqs
fqarray
=(
$fqs
)
if
[[
$numfq
==
1
]]
if
[[
$numfq
==
2
]]
then
hisat_opt
=
"-1
${
fqarray
[0]
}
-2
${
fqarray
[1]
}
"
else
hisat_opt
=
"-U
$fqarray
[0]"
hisat_opt
=
"-U
$
{
fqarray
[0]
}
"
fi
if
[
$algo
==
'star'
]
...
...
preproc_fastq/trimgalore.sh
View file @
96bcf788
...
...
@@ -29,29 +29,32 @@ if [[ -z $pair_id ]]; then
usage
fi
fqs
=
''
i
=
0
numfq
=
${#
fqs
[@]
}
while
[[
$i
-le
$numfq
]]
do
fqs
=
"
$fqs
$1
"
i
=
$((
i
+
1
))
shift
1
done
if
[[
-f
$fq1
]]
if
[[
-z
$fq1
]]
then
i
=
0
numfq
=
${#
fqs
[@]
}
while
[[
$i
-le
$numfq
]]
do
fqs
=
"
$fqs
$1
"
i
=
$((
i
+
1
))
shift
1
done
else
fqs
=
"
$fq1
"
r1base
=
"
${
fq1
%.fastq*
}
"
if
[[
-f
$fq2
]]
then
fqs+
=
"
$fq2
"
r2base
=
"
${
fq2
%.fastq*
}
"
fi
fi
if
[[
-f
$fq2
]]
then
fqs+
=
"
$fq2
"
r2base
=
"
${
fq2
%.fastq*
}
"
fi
numfq
=
${#
fqs
[@]
}
numfq
=
0
for
k
in
$fqs
do
numfq
=
$((
numfq
+
1
))
done
copts
=
'-q 25 --illumina --gzip --length 35'
if
[[
$numfq
==
1
]]
if
[[
$numfq
==
2
]]
then
copts
=
"
$copts
--paired"
fi
...
...
@@ -70,7 +73,7 @@ then
mv
*
_val_2.fq.gz
${
pair_id
}
.trim.R2.fastq.gz
else
mv
*
_trimmed.fq.gz
${
pair_id
}
.trim.R1.fastq.gz
cp
${
pair_id
}
.trim.R1.fastq.gz
${
pair_id
}
.trim.R2.fastq.gz
#
cp ${pair_id}.trim.R1.fastq.gz ${pair_id}.trim.R2.fastq.gz
fi
if
[[
$filter
==
1
]]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment