Tutorial – using RStudio in the cloud

The following tutorial will demonstrate how to create an account on AWS (Amazon Web Services), load an AMI Image for RStudio, and thereafter use RStudio, all at no charge. Readers who are experienced in using cloud platforms may find the instructions quite basic. For other users, the tutorial should provide helpful initial guidance on using AWS.

Please read the Warning message below prior to proceeding.

Warning: Note that AWS requires a credit card for signup. Users must be careful and select only the options for the FREE TIER. The AWS agreement permits Amazon to bill users for incurred charges. Due to this reason, users should use the platform judiciously to avoid potentially expensive unexpected charges from servers or services that are left running.


As of this time, Azure and Google Cloud offer user signups with provisions to avoid inadvertent charges. However, AWS has the highest market share among all cloud vendors, and users are likely to encounter AWS in most workplace situations. Hence, this tutorial focuses on AWS rather than the alternatives.

Instructions on how to close your account have also been provided at the end of the tutorial, should you wish to discontinue your use of AWS (and thus also prevent any charges):

  1. Go to https://aws.amazon.com/and click on the Create an AWS Account button at the top-right:
  1. An AWS account generally includes 12 months of initial free tier access. Enter your information and click on Continue:
  1. Select your Account type (such as Personal) and enter your contact information:
  1. Enter the payment information. AWS requires a credit card for signup. Note that users must utilize AWS resources very carefully and judiciously in order to ensure that there are no inadvertent charges:
  1.  You'll receive a confirmation once the payment information has been verified:
  1. Select the Basic Plan (Free):

The confirmation page after selecting the Basic Plan is as follows:

  1. Log in to AWS with your credentials:

  1. The first page shows some of the services in AWS. The top-right shows the region of your instance. AWS supports multiple regions, and users can select from a range of geographically-dispersed locations:
  1. Clicking on the top-left drop-down menu for Services will bring up the different services available. Some of the important ones are highlighted here:
  1. Click on EC2:
  1. AWS provides the option to launch multiple different OSs. While we can start a new instance afresh with a selected OS, we will be instead using an AMI image. AMIs are preconfigured images with installed software. Note that using an AMI image is not required, but one is being used here for the tutorial:

  1. Click on Community AMIs on the left menu bar and search for RStudio. Select the first option and click on the Select button:
  1. Select the free tier option (t2.micro) and click Next: Configure Instance Details:
  1. Select the default options on the next page and click Next:Add Storage:
  1. Select the default storage options and click on Add Tags:
  1. Click Next:Configure Security Group:
  1. Security groups specify the network access rules for the server. For our tutorial, we will select All TCP and click Review and Launch:
  1. Click Launch:
  1. Select Create a new key pair, and click Download Key Pair. Once the key finishes downloading, click on the Launch Instances button:
  1. Click on the instance ID:
  1. Once the status of the instance ID is displayed as running, copy the name of the server, which can be viewed in the bottom panel:
  1. Open a new browser, enter the name of the server as the URL, and hit Enter. This will bring up RStudio. Log in with the ID rstudio and password rstudio:
  1. This will bring up the RStudio console. This is a complete R environment and you can execute R code just as you would in a local installation of R and RStudio:
  1. Once you have finished using R Studio, make sure that you terminate the instance. Termination stops the billing process. Even though we are using the free tier account, it is good practice to stop or terminate the instance once you have finished your work:
  1. Click Sign Out to log out of the AWS console:

Azure also offers free account signups at https://azure.microsoft.com/en-us/free/, as shown in the following screenshot:

Google's free cloud signup form is available at https://cloud.google.com/free/, as shown in the following screenshot:

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.138.172.130