如何在R包代码中找到函数的代码?

如何在R包代码中找到函数的代码?,r,R,我想找到DBI::dbGetRowsAffected的代码。我从下载了包DBI,并通过dbGetRowsAffected找到了它: #' The number of rows affected #' #' This method returns the number of rows that were added, deleted, or updated #' by a data manipulation statement. #' #' @template methods #' @templa

我想找到
DBI::dbGetRowsAffected
的代码。我从下载了包
DBI
,并通过
dbGetRowsAffected
找到了它:

#' The number of rows affected
#'
#' This method returns the number of rows that were added, deleted, or updated
#' by a data manipulation statement.
#'
#' @template methods
#' @templateVar method_name dbGetRowsAffected
#'
#' @inherit DBItest::spec_meta_get_rows_affected return
#'
#' @inheritParams dbClearResult
#' @family DBIResult generics
#' @export
#' @examples
#' con <- dbConnect(RSQLite::SQLite(), ":memory:")
#'
#' dbWriteTable(con, "mtcars", mtcars)
#' rs <- dbSendStatement(con, "DELETE FROM mtcars")
#' dbGetRowsAffected(rs)
#' nrow(mtcars)
#'
#' dbClearResult(rs)
#' dbDisconnect(con)
setGeneric("dbGetRowsAffected",
  def = function(res, ...) standardGeneric("dbGetRowsAffected"),
  valueClass = "numeric"
)
受影响的行数 #' #'此方法返回已添加、删除或更新的行数 #'通过数据操作语句。 #' #“@模板方法 #“@templateVar方法\u名称dbGetRowsAffected #' #“@inherit DBItest::spec\u meta\u get\u rows\u受影响的返回 #' #“@inheritParams dbClearResult” #'@family DBIResult泛型 #“@出口 #“@示例
#“con如github自述中所述:

DBI包定义了R和数据库管理系统(DBMS)之间的公共接口

该包定义了一个接口,而不实现方法本身。这些方法在这里定义,但在实现接口的驱动程序包中实现,并且需要DBI包