我尝试基于包尾中定义的 as.mcmc 创建一个方法 as.mcmc.mcmcComposite。这是代码:
#' as.mcmc Extract mcmc object from a result to be used with coda package
#' @title Extract mcmc object from a result to be used with coda package
#' @author Marc Girondot
#' @return A mcmc.list object
#' @param x A result object
#' @description Take a mcmcComposite object and create a mcmc.list object
#' @examples
#' # Try
#’ method as.mcmc mcmcComposite
#' @export
as.mcmc.mcmcComposite <-
function(x) {
return(x$resultMCMC)
}
它运行良好,但在检查时会产生错误:
* checking Rd \usage sections ... NOTE
S3 methods shown with full name in documentation object 'as.mcmc.mcmcComposite':
‘as.mcmc.mcmcComposite’
The \usage entries for S3 methods should use the \method markup and not
their full name.
See the chapter ‘Writing R documentation files’ in the ‘Writing R
Extensions’ manual.
我不明白如何纠正这样的错误。感谢您的任何建议
马克·吉伦多