[R-pkg-devel] import 'as' from another package

Tim Keitt tke|tt @end|ng |rom gm@||@com
Mon Jul 20 18:06:08 CEST 2020

I have

  if (!inherits(x, "RasterLayer")) x <- as(x, "RasterLayer")

in a package and its not finding the coerce definition from the raster
package. I know I need to add an @import roxygen2 directive of some kind,
but I'm not sure the correct syntax. My first try generated a warning that
it was not needed.

What is the correct way to do this? Or does raster need to export this


	[[alternative HTML version deleted]]

More information about the R-package-devel mailing list