Difference between revisions of "R"

From UMIACS
Jump to navigation Jump to search
 
(One intermediate revision by one other user not shown)
Line 1: Line 1:
R installation instructions for Windows
+
This page contains steps for installing R on Windows.
  
 
==Basic Installation==
 
==Basic Installation==
Line 8: Line 8:
 
#Navigate to the directory you downloaded the installer to.
 
#Navigate to the directory you downloaded the installer to.
 
#Run the .exe and step through the installer.
 
#Run the .exe and step through the installer.
[[Image:R_Install_1.PNG]]
+
#*[[Image:R_Install_1.PNG]]
 +
#*Note: There will be a warning when you start the installer that says the full installation requires administrative privileges, disregard this message.
 +
#*[[Image:R_Install_2.PNG]]
 +
#Accept the License Agreement and continue.
 +
#*[[Image:R_Install_3.PNG]]
 +
#When prompted, choose an installation folder wherever you would like it within your home directory.
 +
#*[[Image:R_Install_4.PNG]]
 +
#Select the components that you wish to install, the defaults for this is fine.
 +
#*[[Image:R_Install_5.PNG]]
 +
#If you wish to customize the options for the startup environment then click Yes when prompted and proceed to the below section. If you are unsure what these are, select "No" (can still be changed later).
 +
#*[[Image:R_Install_6.PNG]]
  
 
+
==Customized Options==
*Note: There will be a warning when you start the installer that says the full installation requires administrative privileges, disregard this message.
+
#Name the folder that will appear in the start menu. The default "R" is acceptable for this.
[[Image:R_Install_2.PNG]]
+
#*[[Image:R_Install_10.PNG]]
 
+
#Finalize your installation options and hit Next to begin the installation.
 
+
#*[[Image:R_Install_11.PNG]]
*Accept the License Agreement and continue.
+
#After stepping through the dialog, R will install itself to the folder you specified.
[[Image:R_Install_3.PNG]]
+
#Finish and close the setup. R is now installed locally on your account.
 
+
#*[[Image:R_Install_12.PNG]]
 
 
*When prompted, choose an installation folder wherever you would like it within your home directory.
 
[[Image:R_Install_4.PNG]]
 
 
 
 
 
*Select the components that you wish to install, the defaults for this is fine.
 
[[Image:R_Install_5.PNG]]
 
 
 
 
 
*If you wish to customize the options for the startup environment then click Yes when prompted. If you are unsure what these are select "No", the defaults can be altered later.
 
[[Image:R_Install_6.PNG]]
 
 
 
 
 
For customized options see the section below
 
 
 
 
 
*Name the folder that will appear in the start menu, the default "R" is acceptable for this.
 
[[Image:R_Install_10.PNG]]
 
 
 
 
 
*Finalize your installation options and hit Next to begin the installation.
 
[[Image:R_Install_11.PNG]]
 
 
 
 
 
*After stepping through the dialog R will install itself to the folder you specified.
 
 
 
 
 
*Finish and close the setup. R is now installed locally on your account.
 
[[Image:R_Install_12.PNG]]
 
  
 
==Customized Startup Environment==
 
==Customized Startup Environment==
*From the customized startup environment options prompt, if you wish to go through the customized startup environment dialog select "Yes" here. Any of these options can be altered at a later time after installation if you decide you have a change in preference.
+
#From the customized startup environment options prompt, if you wish to go through the customized startup environment dialog, select "Yes" here. Any of these options can be altered at a later time after installation if you decide you have a change in preference.
[[Image:R_Install_6.PNG]]
+
#*[[Image:R_Install_6.PNG]]
 
+
#The first prompt will determine which interface you wish to use. MDI (one main window for all R programs) or SDI (separate windows for each R program) If you have a preference, select which option you prefer.
 
+
#*[[Image:R_Install_7.PNG]]
*The first prompt will determine which interface you wish to use. MDI (one main window for all R programs) or SDI (separate windows for each R program) If you have a preference, select which option you prefer.
+
#Next, determine how you wish the help format to be displayed. You can choose from either plain text format or HTML formatted.
[[Image:R_Install_7.PNG]]
+
#*[[Image:R_Install_8.PNG]]
 
+
#Finally, determine how you would like R to handle the proxy settings in Internet Explorer, whether you would like to use the standard settings or make use of internet2.dll.
 
+
#*[[Image:R_Install_9.PNG]]
*Next, determine how you wish the help format to be displayed. You can choose from either plain text format or HTML formatted.
+
#The startup environment customization for R is now finished. See the above sections for the following steps.
[[Image:R_Install_8.PNG]]
 
 
 
 
 
*Finally, determine how you would like R to handle the proxy settings in Internet Explorer, whether you would like to use the standard settings or make use of internet2.dll.
 
[[Image:R_Install_9.PNG]]
 
 
 
 
 
*That concludes the startup environment customization options for R. The following steps are the same as the above.
 
  
 
==Opening R scripts with RScript==
 
==Opening R scripts with RScript==
 
Users can open a file with R to a command terminal window via RScript.
 
Users can open a file with R to a command terminal window via RScript.
From within the \bin\x64 folder at the location that you installed R to you can run:
+
From within the \bin\x64 folder at the location that you installed R to you can run: <pre>Rscript path\to\file\test.R</pre>
<pre>
 
RScript path\to\file\test.R
 
</pre>
 

Latest revision as of 18:09, 23 July 2018

This page contains steps for installing R on Windows.

Basic Installation

  1. To retrieve the latest version of R from here: http://cran.r-project.org/
  2. Select "Download R for Windows" from the top of the screen
  3. Then click "Install R for the first time" on the first line
  4. This will take you to a download page, click "Download R<version number> for Windows" to begin the installation
  5. Navigate to the directory you downloaded the installer to.
  6. Run the .exe and step through the installer.
    • R Install 1.PNG
    • Note: There will be a warning when you start the installer that says the full installation requires administrative privileges, disregard this message.
    • R Install 2.PNG
  7. Accept the License Agreement and continue.
    • R Install 3.PNG
  8. When prompted, choose an installation folder wherever you would like it within your home directory.
    • R Install 4.PNG
  9. Select the components that you wish to install, the defaults for this is fine.
    • R Install 5.PNG
  10. If you wish to customize the options for the startup environment then click Yes when prompted and proceed to the below section. If you are unsure what these are, select "No" (can still be changed later).
    • R Install 6.PNG

Customized Options

  1. Name the folder that will appear in the start menu. The default "R" is acceptable for this.
    • R Install 10.PNG
  2. Finalize your installation options and hit Next to begin the installation.
    • R Install 11.PNG
  3. After stepping through the dialog, R will install itself to the folder you specified.
  4. Finish and close the setup. R is now installed locally on your account.
    • R Install 12.PNG

Customized Startup Environment

  1. From the customized startup environment options prompt, if you wish to go through the customized startup environment dialog, select "Yes" here. Any of these options can be altered at a later time after installation if you decide you have a change in preference.
    • R Install 6.PNG
  2. The first prompt will determine which interface you wish to use. MDI (one main window for all R programs) or SDI (separate windows for each R program) If you have a preference, select which option you prefer.
    • R Install 7.PNG
  3. Next, determine how you wish the help format to be displayed. You can choose from either plain text format or HTML formatted.
    • R Install 8.PNG
  4. Finally, determine how you would like R to handle the proxy settings in Internet Explorer, whether you would like to use the standard settings or make use of internet2.dll.
    • R Install 9.PNG
  5. The startup environment customization for R is now finished. See the above sections for the following steps.

Opening R scripts with RScript

Users can open a file with R to a command terminal window via RScript.

From within the \bin\x64 folder at the location that you installed R to you can run:

Rscript path\to\file\test.R