Install and Configure R and RStudio

32
Installing and configuring & Studio useR@HSPH Kazuki Yoshida, M.D. MPH-CLE student FREEDOM TO KNOW

Transcript of Install and Configure R and RStudio

Page 1: Install and Configure R and RStudio

Installing and configuring

& StudiouseR@HSPH

Kazuki Yoshida, M.D. MPH-CLE student

FREEDOMTO  KNOW

Page 2: Install and Configure R and RStudio

Create a folder for this study group

This will be your working directory.Put everything related here!

Page 3: Install and Configure R and RStudio

First download and installhttp://www.r-project.org

Page 4: Install and Configure R and RStudio

http://www.r-project.org

Page 5: Install and Configure R and RStudio
Page 6: Install and Configure R and RStudio

Choose the one you need

Page 7: Install and Configure R and RStudio

Download and install this

Page 8: Install and Configure R and RStudio

GUI toolkit

R itself

R itself

Install both files

Page 9: Install and Configure R and RStudio

Then download and installStudio

http://rstudio.org

Page 10: Install and Configure R and RStudio

http://rstudio.org Click here

Page 11: Install and Configure R and RStudio

http://rstudio.org

Watch this!

Page 12: Install and Configure R and RStudio

OR

Download and install RStudio Desktop appropriate for your computer

Page 13: Install and Configure R and RStudio

Make sure you installed

both

Page 14: Install and Configure R and RStudio

First you’ll configure Studio

Page 15: Install and Configure R and RStudio

Open R Studio

Page 16: Install and Configure R and RStudio

ConsolePlot

Workspace

Page 17: Install and Configure R and RStudio

Tools-Options

Page 18: Install and Configure R and RStudio

Choose folder you created

Page 19: Install and Configure R and RStudio

Restart RStudioafter cofiguration

Choose mirror geographically close

Page 20: Install and Configure R and RStudio

CRANmirror

Page 22: Install and Configure R and RStudio

Working directory

Folder your are working in. Make sure it

is the one you created

Page 23: Install and Configure R and RStudio

Createa script

Page 24: Install and Configure R and RStudio
Page 25: Install and Configure R and RStudio

Source

Console Plot

WorkspaceThis is where you write code

You see dataset names here

You see outputs here

Page 26: Install and Configure R and RStudio

Install additional packages

Page 27: Install and Configure R and RStudio

foreign sas7bdat XML

gdataxlsx

Install packages!

Page 28: Install and Configure R and RStudio

Use text filesuch as csvif possible

Page 30: Install and Configure R and RStudio

For comma-, tab-, or space-separated text,

GUI is available

Page 31: Install and Configure R and RStudio

Text

Page 32: Install and Configure R and RStudio