Le-Huynh Truc-Ly
  • home
  • projects
  • r-code
  • blog
  • publications
  • CV
  • get in touch!
    • LinkedIn
    • email
    • GitHub

On this page

  • Warning
  • Solution
  • Further information

Warning: ’‘::’’ or ’‘:::’’ imports not declared from: package_name

warning
R
R-package
Warning when creating new function in Rpackage

Warning

I am creating a new function in my Rpackage. After running devtools::check(), I get this WARNING:

checking dependencies in R code ... WARNING
'::' or ':::' imports not declared from:
  ‘dplyr’ 

Solution

Add dplyr to Imports in the DESCRIPTION file.

usethis::use_package("dplyr")
#> Adding dplyr to Imports
#> Refer to functions with dplyr::fun()

Further information

Dependencies: What does your package need?, R Packages by Hadley Wickham and Jenny Bryan

© 2021-2026 Le-Huynh Truc-Ly

 

This website is built with GitHub, R, and Quarto