패키지를 빌드 할 때이 오류가 발생합니다. 이 오류를 방지하기위한 단계를 알려주시겠습니까?
#' Square a number
#'
#' Takes in any numeric value and squares it
#' @param x A value to be squared
#' @return The square of the input
#' @export
#' @example
square <- function(x)
{
return(x^2)
}
빌드를 누를 때 발생하는 오류는 다음과 같습니다.
==> roxygenize('.', roclets=c('rd', 'collate', 'namespace'))
* checking for changes ... ERROR
Error : example requires a value
다음을 시도하십시오.
#' @title
#' Square a number
#'
#' @description
#' Takes in any numeric value and squares it
#'
#' @param x A value to be squared
#' @return The square of the input
#'
#' @export
#' @examples
#' square(2) # 2 squared
square <- function(x)
{
return(x^2)
}
또한 최신 roxygen2
패키지로 플레이하십시오 .
이 기사는 인터넷에서 수집됩니다. 재 인쇄 할 때 출처를 알려주십시오.
침해가 발생한 경우 연락 주시기 바랍니다[email protected] 삭제
몇 마디 만하겠습니다