Skip to contents

Analyse all .R files in one or more packages and report line counts by type: total, blank, comments, roxygen comments, function bodies and lines in test files. The package name and version are also returned.

Usage

get_code_stats(path = ".")

Arguments

path

A character vector or list of local package paths.

Value

A pkginspectr_tbl with one row per package containing summary line counts.

Examples

if (FALSE) { # \dontrun{
# Analyse the installed "stats" package
get_code_stats(system.file(package = "stats"))
} # }