Skip to content

Commit

Permalink
updated loading R
Browse files Browse the repository at this point in the history
  • Loading branch information
spocks committed Apr 1, 2021
1 parent 4a80854 commit 3d56b49
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 8 deletions.
4 changes: 3 additions & 1 deletion R/code2.R
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,11 @@ print(N)

registerDoParallel(N)

foreach (i= 1:(2*N) ) %dopar% {
foreach (i= 1:100) %dopar% {
Sys.sleep(10)

}

stopImplicitCluster()

print(proc.time() - t0)
Expand Down
6 changes: 4 additions & 2 deletions R/doc.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,10 @@ salloc -c 1 -t 0:15:0 --mem 2G

Once in the node, load R as:
```{r eval=FALSE}
module load R/3.6.1
module load R
```
This will load latest version of R. You can see all available version by pressing
Tab key after **module load R**.
After this you can use Rscript or R interactive session. Type R and see if it works.
Note that once time is over you will be disconnected from the node and all unsaved data will be gone.

Expand All @@ -56,7 +58,7 @@ It is the only node with internet access.
salloc --partition=build -c 1 -t 1:0:0 --mem 2G
#load R
module load R/3.6.1
module load R
#run R
R
Expand Down
12 changes: 7 additions & 5 deletions R/doc.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,14 @@ salloc -c 1 -t 0:15:0 --mem 2G
Once in the node, load R as:

``` r
module load R/3.6.1
module load R
```

After this you can use Rscript or R interactive session. Type R and see
if it works. Note that once time is over you will be disconnected from
the node and all unsaved data will be gone.
This will load latest version of R. You can see all available version by
pressing Tab key after **module load R**. After this you can use Rscript
or R interactive session. Type R and see if it works. Note that once
time is over you will be disconnected from the node and all unsaved data
will be gone.

## Installing R packages:

Expand All @@ -63,7 +65,7 @@ the only node with internet access.
salloc --partition=build -c 1 -t 1:0:0 --mem 2G

#load R
module load R/3.6.1
module load R

#run R
R
Expand Down

0 comments on commit 3d56b49

Please sign in to comment.