Commit 86875148 authored by Aadil M. Alli's avatar Aadil M. Alli

Added R Example in FAQ

parent c1d081e7
......@@ -322,7 +322,7 @@ Deactivate the environment if it's active:
**R Example**
Below are directions on using a simple virtual environment with renv. It is one of the main packages used to manage virtual environments in R.
Create a new project and initialize renv:
Create a virtual environment:
```
renv::init()
```
......@@ -330,11 +330,15 @@ Activate the environment:
```
renv::activate()
```
Install a package:
Your current line should be prefixed with the environment name:
```
(research1) user@super-computer
```
Install new package:
```
install.packages("package_name")
```
Deactivate an environment:
Deactivate the environment if it's active:
```
renv::deactivate()
```
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment