Learn R Programming

⚠️There's a newer version (1.1.4) of this package.Take me there.

renv

Overview

The renv package is a new effort to bring private project-local R libraries to your projects. The goal is for renv to be a robust, stable replacement for the Packrat package, with fewer surprises and better default behaviors.

Workflow

The general workflow when working with renv is:

  1. Call renv::init() to initialize a new project-local environment, with a private R library;

  2. Work in the project as normal, installing and removing new R packages as they are needed in the project,

  3. Call renv::snapshot() to save the state of the project library to the lockfile (called renv.lock),

  4. Call renv::restore() to restore the state of the project library, based on the state of the lockfile previously generated by renv::snapshot().

See the Introduction vignette for more details.

Copy Link

Version

Install

install.packages('renv')

Monthly Downloads

377,391

Version

0.4.0-8

License

MIT + file LICENSE

Issues

Pull Requests

Stars

Forks

Maintainer

Kevin Ushey

Last Published

March 20th, 2025

Functions in renv (0.4.0-8)

modify

Open the Lockfile for Editing
history

View Lockfile History
activate

Activate a Project
config

User-Level Configuration of renv
hydrate

Hydrate a Project
clean

Clean a Project
load

Load a Project
lockfile

Lockfiles
deactivate

Deactivate a Project
status

Status
upgrade

Upgrade renv
project

Retrieve the Active Project
purge

Purge Packages from the Cache
remove

Remove Packages
settings

Project Settings
snapshot

Snapshot a Project
dependencies

Find R Package Dependencies in a Project
equip

Install Required System Libraries
renv-package

Project-local Environments for R
init

Initialize a Project
use_python

Use Python
install

Install Packages
restore

Restore a Project
revert

Revert Lockfile
paths

Path Customization