Foreign function calls to a different package NOTE

前提是你 提交于 2019-12-05 15:54:04

The warning points you toward the 'System and Foreign language interface' chapter of the Writing R Extensions manual, which says specifically (in the Writing Portable Packages section):

It is not portable to call compiled code in R or other packages via .Internal, .C, .Fortran, .Call or .External, since such interfaces are subject to change without notice and will probably result in your code terminating the R process.

You can say what you like about the CRAN maintainers, but they're rarely wrong on technical points, and the reasons are almost always documented somewhere.

Some of your options are:

  • if you don't want to submit to CRAN, you can ignore the NOTE.
  • you could copy the Fortran (or C) code from the other package and incorporate it in your own (you might need to be careful about license, and it would certainly be polite to ask permission)
  • you could ask the maintainers of the other package to implement and export a thin R wrapper around their low-level code
标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!