stuart-lab / signac

R toolkit for the analysis of single-cell chromatin data
https://stuartlab.org/signac/
Other
323 stars 87 forks source link

Error in ClosestFeature function #1681

Closed emanuelavilla closed 5 months ago

emanuelavilla commented 5 months ago

I am running this code

ATAC.merged.cf <- ClosestFeature(ATAC.merged, regions = rownames(ATAC.merged.DARs)) ,

where ATAC.merged is my object and ATAC.merged.DARs the result of FindAllMArkers and looks like

Screenshot 2024-04-09 alle 11 43 34

However, it returned this error I cannot understand

Error in h(simpleError(msg, call)) : error in evaluating the argument 'x' in selecting a method for function 'seqlevels': unable to find an inherited method for function ‘seqinfo’ for signature ‘"NULL"’

timoast commented 5 months ago

Can you show the output of Annotation(ATAC.merged)?

emanuelavilla commented 5 months ago

I checked and it was NULL. So I added the gene annotation to the merged object and now everything works. Thanks

timoast commented 5 months ago

Ok, I have added a more informative error message now when the annotations are missing