Closed smgogarten closed 6 years ago
I found another, perhaps more general instance of this bug but I believe it too has been remedied by this timely fix. Thank you!
Minimal reprex for posterity/in case this surfaces again/others using locked versions:
In 1.18.2
:
library(SeqArray)
packageVersion("SeqArray")
# 1.18.2
gds <- seqOpen(seqExampleFileName("gds"))
table(seqGetFilter(gds)$variant.sel)
# TRUE
# 1348
seqSetFilterCond(gds, maf=0.1, missing.rate=0, .progress=TRUE)
## of selected variants: 36 <------------- :-)
table(seqGetFilter(gds)$variant.sel)
# FALSE TRUE
# 1312 36
dim(seqGetData(gds, "$dosage"))
# [1] 90 36
seqClose(gds)
In 1.19.6
:
library(SeqArray)
packageVersion("SeqArray")
# 1.19.6
gds <- seqOpen(seqExampleFileName("gds"))
table(seqGetFilter(gds)$variant.sel)
# TRUE
# 1348
seqSetFilterCond(gds, maf=0.1, missing.rate=0, .progress=TRUE)
## of selected variants: 1348 <------------- ! (too many)
table(seqGetFilter(gds)$variant.sel)
# FALSE TRUE
# 1312 36 <------------- !
dim(seqGetData(gds, "$dosage"))
# [1] 90 1348 <------------- ! (too many)
seqClose(gds)
In most recent update, 1.19.7
:
library(SeqArray)
packageVersion("SeqArray")
# 1.19.7
gds <- seqOpen(seqExampleFileName("gds"))
table(seqGetFilter(gds)$variant.sel)
# TRUE
# 1348
seqSetFilterCond(gds, maf=0.1, missing.rate=0, .progress=TRUE)
## of selected variants: 36 <------------- :-)
table(seqGetFilter(gds)$variant.sel)
# FALSE TRUE
# 1312 36
dim(seqGetData(gds, "$dosage"))
# [1] 90 36
seqClose(gds)
Setting a filter with
action="intersect"
results in different lengths returned for variant.id and chromosome: