Skip to content

Commit

Permalink
Merge pull request #18 from selfdecode/feat/life-brain
Browse files Browse the repository at this point in the history
feat: Life&Brain
  • Loading branch information
adrianodemarino committed Sep 25, 2023
2 parents d312ad6 + a9dd7c8 commit b92a481
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion src/snps/io/reader.py
Original file line number Diff line number Diff line change
Expand Up @@ -1046,7 +1046,16 @@ def parser():
"Chr": NORMALIZED_DTYPES["chrom"],
},
)

if df.shape[1] == 1:
# Life&Brain uses "," as sep
df = pd.read_csv(
io.StringIO(data),
engine="c",
dtype={
"Position": NORMALIZED_DTYPES["pos"],
"Chr": NORMALIZED_DTYPES["chrom"],
},
)
# reserve columns we want out
assert "rsid" not in df.columns
assert "chrom" not in df.columns
Expand Down

0 comments on commit b92a481

Please sign in to comment.