Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Statistical-Genetics
jass_preprocessing
Commits
845dfd26
Commit
845dfd26
authored
Oct 30, 2019
by
Hanna JULIENNE
Browse files
filter ambiguous SNPs
parent
fa601f18
Changes
1
Hide whitespace changes
Inline
Side-by-side
jass_preprocessing/map_reference.py
View file @
845dfd26
...
...
@@ -23,6 +23,9 @@ def read_reference(gwas_reference_panel, mask_MHC=False, minimum_MAF=None, regio
ref
=
pd
.
read_csv
(
gwas_reference_panel
,
header
=
None
,
sep
=
"
\t
"
,
names
=
[
'chr'
,
"pos"
,
"snp_id"
,
"ref"
,
"alt"
,
"MAF"
],
index_col
=
"snp_id"
)
#Filter Strand ambiguous
ref
=
ref
.
loc
[
~
(
ref
.
ref
+
ref
.
alt
).
isin
([
"AT"
,
"TA"
,
'CG'
,
'GC'
])]
if
mask_MHC
:
ref
=
ref
.
loc
[(
ref
.
chr
!=
6
)
|
(
ref
.
pos
<
28477797
)
|
(
ref
.
pos
>
33448354
)]
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment