devtools (version 0.8)

reload: Unload and reload package.

Description

If the package is not loaded already, this does nothing.

Usage

reload(pkg = ".")

Arguments

pkg
package description, can be path or package name. See as.package for more information

Details

See the caveats in detach for the many reasons why this might not work. If in doubt, quit R and restart.

Examples

Run this code
# Reload package that is in current directory
reload(".")

# Reload package that is in ./ggplot2/
reload("ggplot2/")

# Can use inst() to find the package path
# This will reload the installed ggplot2 package
reload(inst("ggplot2"))

Run the code above in your browser using DataCamp Workspace