zwdzwd / sesame

🍪 SEnsible Step-wise Analysis of DNA MEthylation BeadChips

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ERROR: values must be length 1, but FUN(X[[12]]) result in length 0

neverseverette opened this issue · comments

I’m trying to run Rstudio with sesame() to create 96 vcfs. However, 94 vcf files are created out of the 96 with the error “ERROR: values must be length 1, but FUN(X[[12]]) result in length 0”. The inputs I am utilizing are written below:

sesameDataCache()
(file) = openSesame("E:/pathway_directory", prep="QCDPB", func=NULL)
for(name in names(file)){tryCatch({formatVCF(file[[name]], vcf = paste("E:/destination_directory/", name, ".vcf", sep=''),genome = "hg19", annoS = NULL, annoI = NULL, verbose = FALSE)}, error=function(e){cat("ERROR :",conditionMessage(e), "\n")})}
I wasn’t sure if there was something amiss with the code I’m executing or the files I’m using to run it. Any thoughts on why I vcf files aren’t being created for these two files? And what might be contributing to these error messages?

Hey,

Did you receive a response? I am having the same issue as well.

Thank you.

Hmm, are you getting error with EPIC array? what's the error message with verbose=TRUE and vcf=NULL?

I'm still getting the same error message with verbose=TRUE and vcf = NULL. When running that for loop, it only executes a certain number of vcfs for each sample. The samples that are showing the error message are samples that passed in Sesame and in GS. I'm not sure why only a handful of samples aren't creating vcfs.

Sorry it's been a while. For what's worth, maybe the new formatVCF function that simplifies the process can solve the issue above? A public dataset to reproduce this error would be helpful for me to troubleshoot.

sdf = openSesame("~/repo/InfiniumTestIDATs/EPIC/GSM2995280_201868590258_R01C01", func=NULL, prep="")
anno = read_tsv(gzcon(url("https://github.com/zhou-lab/InfiniumAnnotationV1/raw/main/Anno/EPIC/EPIC.hg38.snp.tsv.gz")))
formatVCF(sdf, anno, vcf="~/Downloads/test_output.vcf")