Intermediate Importing Data in R

Start Free Preview

Buying via our links supports this free directory · Affiliate disclosure.
Course facts
  • Payment: Free Preview (Paid Upgrade)
  • Learning style: Self-paced, start anytime
  • Format: Text & Interactive
  • Video access: Streaming Only
  • Before you start: Introduction to Importing Data in R
DataCamp details
  • Chapters: 5
Created byDataCamp
Available onDataCamp

Course Details
Learning Style

Start Anytime

Level

Intermediate

Study Mode

100% Online

Duration

Short (< 10 Hours)

Languages
Audio Language

English

Outcomes
Certificate

Certificate of Completion

Price & Terms
Pricing Model

Free Preview (Paid Upgrade)

Technical
Content Medium

Text & Interactive

Video Access

Streaming Only

Specification
Access

Subscription

SKU: intermediate-importing-data-r Category: Tags: , Brand:

Import data into R from relational databases with SQL, from the web and JSON APIs, and from SAS, STATA and SPSS files, in interactive exercises.

At a glance
Duration3 hrs
LevelIntermediate
CertificateCertificate of Completion
LanguageEnglish
AccessSubscription
Add your review
Add to wishlistAdded to wishlistRemoved from wishlist 0
Add to compare

This course is about getting data into R from relational databases, the web and other statistical software. You connect to a database and write SQL queries so the database does part of the computation and only the data you need comes back. You make HTTP requests to download files and call APIs that return JSON. You also read SAS, STATA and SPSS files with the haven and foreign packages.

What You Will Achieve

  • Connect R to a relational database, list its tables and import the ones you need
  • Send SQL queries from R, fetch the results and clear them when the work is done
  • Download files over HTTP and turn JSON from an API into R objects with httr and jsonlite
  • Load SAS, STATA and SPSS data with haven or foreign and check what was imported


Program Overview

Relational Databases and SQL Queries in R

Linking R to a database, bringing in its tables, and moving computation to the database side with SQL.

  • Establishing and inspecting a connection
  • How database tables relate
  • SQL queries and joins run from inside R
  • DBI internals and result handling

Web Data over HTTP, APIs and JSON

Importing files stored on the web and extracting structured information from APIs.

  • HTTP basics and secure imports
  • Flat, Excel and text files read from the web
  • Requests with httr
  • JSON with jsonlite, toJSON, minify and prettify

Files from SAS, STATA and SPSS

Reading the file formats of other statistical software packages into R with two different packages.

  • Importing with haven
  • Importing with foreign
  • Turning imported values into factors
  • A short excursion into correlation

Certificate Awarded (Paid)


Job Outlook

These skills are used wherever analysts work in R with information held in company databases, web APIs or files produced by SAS, STATA and SPSS.


Our take

Good for: R users who need to pull data from databases, web APIs and other statistical packages into their own analyses.

Keep in mind: Each chapter is built around specific R packages, including DBI, httr, jsonlite, haven and foreign, so the skills tie closely to those tools.

Bottom line: A practical run through three import routes into R: databases with DBI and SQL, web data with httr and jsonlite, and other packages’ files with haven and foreign.

Frequently Asked Questions

Which R packages does the course use?

The database chapters work through DBI, the web chapters use httr for HTTP requests and jsonlite for JSON, and the final chapter reads statistical software files with both haven and foreign, so you see two ways of doing the same job.

Which web API appears in the exercises?

The JSON chapter has you call the OMDb API and convert its JSON response into R objects. You then practice turning R data back into JSON and switching between minified and prettified output.

Why send SQL queries instead of importing whole tables?

Importing an entire table when you need only a small part of it is wasted effort. Queries let the database handle some of the computation, including joins, so R receives just the data you asked for.

User Reviews

0.0 out of 5
★★★★★
0
★★★★★
0
★★★★★
0
★★★★★
0
★★★★★
0

No reviews yet. Be the first to review this course.

There are no reviews yet.

Write your review

Reviews can only be posted by registered learners. Log in, then you will return here to post.

×

    Report this page
    Intermediate Importing Data in R
    Intermediate Importing Data in R
    LiveTalent
    Logo
    Compare items
    • Total (0)
    Compare
    0