Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: There is no SNP! #107

Open
jane-edgeloe opened this issue Mar 22, 2024 · 0 comments
Open

Error: There is no SNP! #107

jane-edgeloe opened this issue Mar 22, 2024 · 0 comments

Comments

@jane-edgeloe
Copy link

Hello, I am running SNPrelate on my genlight file from DART, and converting it to a gds. Using the code bellow, I get an error at the SNP pruning step. It says I have No SNP. Is this a known bug currently or have you got any troubleshooting ideas? see code bellow. Thanks

if (!require("BiocManager", quietly = TRUE))
install.packages("BiocManager")

BiocManager::install("SNPRelate")
gl2gds(gl.secondaries.filtered, outfile = "glsecondariesfiltered7.gds", outpath = "C:/Users/21981245/Desktop/DaRT workshop")
gds <- snpgdsOpen("glsecondariesfiltered7.gds")
gds
str(gds)
names(gds)
gl.secondaries.filtered
gds.pruned <-snpgdsLDpruning(gds, sample.id=NULL, snp.id=NULL, autosome.only=TRUE,
remove.monosnp=TRUE, maf=NaN, missing.rate=NaN,
method=c("composite", "r", "dprime", "corr"), slide.max.bp=500000L,
slide.max.n=NA, ld.threshold=0.1, start.pos=c("random", "first", "last"),
num.thread=1L, verbose=TRUE)

ERROR: SNP pruning based on LD: Excluding 4,984 SNPs on non-autosomes
Error in .InitFile2(cmd = paste(ifelse(inherits(gdsobj, "SeqVarGDSClass"), :
There is no SNP!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant