Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
B
biopet.biopet
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Analyze
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Mirrors
biopet.biopet
Commits
7313c86d
Commit
7313c86d
authored
10 years ago
by
Peter van 't Hof
Browse files
Options
Downloads
Patches
Plain Diff
Change to mergeAlleles
parent
61128d4e
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
biopet-framework/src/main/scala/nl/lumc/sasc/biopet/pipelines/gatk/GatkVariantcalling.scala
+5
-17
5 additions, 17 deletions
.../lumc/sasc/biopet/pipelines/gatk/GatkVariantcalling.scala
with
5 additions
and
17 deletions
biopet-framework/src/main/scala/nl/lumc/sasc/biopet/pipelines/gatk/GatkVariantcalling.scala
+
5
−
17
View file @
7313c86d
...
...
@@ -2,7 +2,7 @@ package nl.lumc.sasc.biopet.pipelines.gatk
import
nl.lumc.sasc.biopet.core.
{
BiopetQScript
,
PipelineCommand
}
import
java.io.File
import
nl.lumc.sasc.biopet.tools.
{
MpileupToVcf
,
VcfFilter
}
import
nl.lumc.sasc.biopet.tools.
{
MpileupToVcf
,
VcfFilter
,
MergeAlleles
}
import
nl.lumc.sasc.biopet.core.config.Configurable
import
nl.lumc.sasc.biopet.extensions.gatk.
{
AnalyzeCovariates
,
BaseRecalibrator
,
GenotypeGVCFs
,
HaplotypeCaller
,
IndelRealigner
,
PrintReads
,
RealignerTargetCreator
,
SelectVariants
,
CombineVariants
,
UnifiedGenotyper
}
import
nl.lumc.sasc.biopet.extensions.picard.MarkDuplicates
...
...
@@ -135,26 +135,14 @@ class GatkVariantcalling(val root: Configurable) extends QScript with BiopetQScr
mergBuffer
+=
(
"9.raw"
->
scriptOutput
.
rawFilterVcfFile
)
if
(
useAllelesOption
.
get
)
{
val
tempFile
=
if
(
mergeList
.
toList
.
size
>
1
)
{
val
allelesTemp
=
CombineVariants
(
this
,
mergeList
.
toList
,
outputDir
+
outputName
+
".alleles_temp.vcf.gz"
)
allelesTemp
.
genotypemergeoption
=
org
.
broadinstitute
.
gatk
.
utils
.
variant
.
GATKVariantContextUtils
.
GenotypeMergeType
.
UNSORTED
add
(
allelesTemp
,
isIntermediate
=
true
)
allelesTemp
.
out
}
else
mergeList
.
toList
.
head
val
alleleOnly
=
new
CommandLineFunction
{
@Input
val
input
:
File
=
tempFile
@Output
val
output
:
File
=
outputDir
+
"raw.allele_only.vcf.gz"
@Output
val
outputindex
:
File
=
outputDir
+
"raw.allele__temp_only.vcf.gz.tbi"
def
commandLine
=
"zcat "
+
input
+
" | cut -f1,2,3,4,5,6,7,8 | bgzip -c > "
+
output
+
" && tabix -pvcf "
+
output
}
add
(
alleleOnly
,
isIntermediate
=
true
)
val
mergeAlleles
=
MergeAlleles
(
this
,
mergeList
.
toList
,
outputDir
+
"raw.allele__temp_only.vcf.gz.tbi"
)
add
(
mergeAlleles
,
isIntermediate
=
true
)
if
(
useHaplotypecaller
.
get
)
{
val
hcAlleles
=
new
HaplotypeCaller
(
this
)
hcAlleles
.
input_file
=
scriptOutput
.
bamFiles
hcAlleles
.
out
=
outputDir
+
outputName
+
".hc.allele.vcf.gz"
hcAlleles
.
alleles
=
a
llele
Only
.
output
hcAlleles
.
alleles
=
mergeA
llele
s
.
output
hcAlleles
.
genotyping_mode
=
org
.
broadinstitute
.
gatk
.
tools
.
walkers
.
genotyper
.
GenotypingOutputMode
.
GENOTYPE_GIVEN_ALLELES
add
(
hcAlleles
)
scriptOutput
.
hcAlleleVcf
=
hcAlleles
.
out
...
...
@@ -165,7 +153,7 @@ class GatkVariantcalling(val root: Configurable) extends QScript with BiopetQScr
val
ugAlleles
=
new
UnifiedGenotyper
(
this
)
ugAlleles
.
input_file
=
scriptOutput
.
bamFiles
ugAlleles
.
out
=
outputDir
+
outputName
+
".ug.allele.vcf.gz"
ugAlleles
.
alleles
=
a
llele
Only
.
output
ugAlleles
.
alleles
=
mergeA
llele
s
.
output
ugAlleles
.
genotyping_mode
=
org
.
broadinstitute
.
gatk
.
tools
.
walkers
.
genotyper
.
GenotypingOutputMode
.
GENOTYPE_GIVEN_ALLELES
add
(
ugAlleles
)
scriptOutput
.
ugAlleleVcf
=
ugAlleles
.
out
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment