how to use %dopar% when only import foreach in DESCRIPTION of a package
How to avoid could not find function "%dopar%" in a function of a package when only imports (not depends) foreach in DESCRIPTION of a package? is there a way like foreach::%dopar% as I use foreach::foreach in function? Thank you.
Code like:
In function
foreach::foreach(1:9) %dopar% {
...}
In DESCRIPTION
Imports:
Matrix,
parallel,
foreach,
doParallel
• 3,666 views
•
link
0 answers
No answers yet.
Log in to answer this question.
Can you please post example code? And of course you did
library(foreach)?No, I did not
library(foreach)because it's a function in a package.Hello Zhilong!
We believe that this post does not fit the main topic of this site.
I do not see any connection to bioinformatics, it looks like an r-package implementation question
For this reason we have closed your question. This allows us to keep the site focused on the topics that the community can help with.
If you disagree please tell us why in a reply below, we'll be happy to talk about it.
Cheers!
Agree. I paste it to SO now. Thank you.