LoslegenKostenlos loslegen

Counting Exported Functions

Packages are the engine of R. They contain all the good stuff, in one neatly contained bundle. The public contents of the package are called exports. The getNamespaceExports("pkg_name") function returns a vector of exported functions.

Diese Übung ist Teil des Kurses

Defensive R Programming

Kurs anzeigen

Anleitung zur Übung

  • Using the getNamespaceExports() function, how many functions does the ggplot2 package export? Store the result in the variable no_of_functions.

Interaktive Übung

Versuche dich an dieser Übung, indem du diesen Beispielcode vervollständigst.

# Count the number of functions in ggplot2
no_of_functions <- ___
Code bearbeiten und ausführen