小编eco*_*013的帖子

使用 devtools+roxygen2 生成的 R 文档文件中缺少 \title{}

我正在使用 devtools 和 roxygen2 编写一个 R 包来做文档。该文档适用于除我的两个 R 文件之外的所有文件。对于这两个,第一个函数的文档文件 (.Rd) 是在没有 \title{} 行的情况下生成的。例如,这是我的普通 rd 文件顶部的样子:

% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/general.R
\name{rmsd}
\alias{rmsd}
\title{Calculates the Root Mean Squared Deviation/Error}
\usage{...`
Run Code Online (Sandbox Code Playgroud)

这是由代码块生成的:

#' Calculates the Root Mean Squared Deviation/Error
#'
#' This function calculates the root mean squared error/deviation (RMSD/E)
#'     between two vectors of numbers.
#'
#' @param x numeric, the first vector
#' @param y numeric, the second vector 
#' …
Run Code Online (Sandbox Code Playgroud)

r devtools s4 rstudio roxygen2

5
推荐指数
0
解决办法
625
查看次数

标签 统计

devtools ×1

r ×1

roxygen2 ×1

rstudio ×1

s4 ×1