CranPackage: Retrieve package information

Description Format Usage Arguments Details Examples

Description

Retrieve package information

Format

An R6 class.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
myPackage <- CranPackage$new("package_name")
myPackage$get_downloads()
myPackage$get_results()
myPackage$get_title()
myPackage$get_description()
myPackage$get_version()
myPackage$get_r_dep()
myPackage$get_imports()
myPackage$get_suggest()
myPackage$get_publish_date()
myPackage$get_license()
myPackage$get_authors()
myPackage$get_maintainer()
myPackage$get_urls()

Arguments

package_name

Name of the R packge.

Details

To create CranPackage objects, you need to use CranPackage$new("package_name").

myPackage$get_downloads() will return the downloads of the package from the RStudio CRAN mirror for the last day, last week, last month and total downloads.

myPackage$get_check_results() will return the CRAN check results of the package.

myPackage$get_title() will return the title of the package.

myPackage$get_description() will return the description of the package.

myPackage$get_version() will return the version of the package.

myPackage$get_r_dep() will return the R dependency of the package.

myPackage$get_imports() will return the R packages imported by the package.

myPackage$get_suggests() will return the R packages suggested by the package.

myPackage$get_publish_date() will return the date the package was published on CRAN.

myPackage$get_license() will return the license under which the package has been released.

myPackage$get_authors() will return the names of the authors of the package.

myPackage$get_maintainer() will return the name of the maintainer of the package.

myPackage$get_urls() will return the URLs associated with the package.

Examples

1
2
3
4
5
6
7
8
## Not run: 
myPackage <- CranPackage$new("dplyr")
myPackage$get_title()
myPackage$get_version()
myPackage$get_r_deps()
myPackage$get_imports()

## End(Not run)

rsquaredacademy/pkginfo documentation built on Nov. 15, 2018, 9:44 p.m.