Closed u2058152 closed 3 years ago
Hey, I can't reproduce this on my end. Would you mind trying a couple things?
First, could you post the output of SessionInfo()
?
Can you confirm genes
and peaks
are GRanges objects: class(genes)
and class(peaks)
?
Can you call the function with ::
like so plyranges::add_nearest_distance(genes, peaks)
?
Finally, do other plyranges
functions work in this session (ie mutate(genes, example = "test")
? I would try restarting & reloading to see if that resolves the issue.
I installed a newer version of R (I was using R 4.0.2) and add_nearest_distance now works. However, when I try to knit an r markdown file I get the following error message:
This sounds like a namespacing issue. In the Rmd you're calling library(plyranges)
right? If you switch your call to plyranges::add_nearest_distance
does that fix it?
Thanks for your help this resolves the problem.
I installed plyranges and carried out the library command. I get an error saying add_nearest_distance command is not found.
Command executed:
Error found: Error in add_nearest_distance(., peaks) : could not find function "add_nearest_distance"