Query Databases and Data frames in R with SQL

Query Databases and Data frames in R with SQLThe link is for database files:https://drive.google.com/file/d/1m7i0qF0HPVyuwx5Wk…ResourcesFirst Steps in RLecture Notes on R and ExamplesQuerying Data Frames in R with SQL using sqldfInstructionsCreate an R Notebook and do the following tasks in separate code chunks:1. (20 pts) In the R Notebook, connect to the SQLite MediaDB.db(https://northeastern.instructure.com/courses/80530/files/9239221/download?download_frd=1)database and then load, using SQL SELECT, the “invoice_items” table into a data frame called rs.Add a new column to rs for the extended price called ExtPrice that is Quantity times Price. UsingR, what is the average extended price (rounded to 2 decimals)? Do not use {sql} chunks for this.2. (30 pts) Using sqldf, write a SQL query against the data frame rs from the question above thatfinds the total amount for each invoice (i.e., the sum of the extended prices for the invoice_itemsin each invoice) and the number of items in the invoice. So, the result set contains rows that eachhave the invoice ID, the total, and the number of items.3. (30 pts) Using R and the result from the prior question, create a scatter plot of the total number ofitems in an invoice (x axis) versus the total (y axis). Add proper axis labels.4. (20 pts) Write and execute a SQL UPDATE statement that applies a 10% discount to the totalamount for each invoice if it has more than 5 items and stores that discounted amount in a newcolumn called DiscPrice. Using a separate {r} chunk show that the query executed properly by2021/6/17 [90 min] DO: Assignment 5 / Query Databases and Dataframes in R with SQL2/2displaying a part of the table. If you cannot use sqldf, then apply to the database directly instead;either are acceptable as long as you use a SQL UPDATE.Requirements: no | R

Place your order
(550 words)

Approximate price: $22

Calculate the price of your order

550 words
We'll send you the first draft for approval by September 11, 2018 at 10:52 AM
Total price:
$26
The price is based on these factors:
Academic level
Number of pages
Urgency
Basic features
  • Free title page and bibliography
  • Unlimited revisions
  • Plagiarism-free guarantee
  • Money-back guarantee
  • 24/7 support
On-demand options
  • Writer’s samples
  • Part-by-part delivery
  • Overnight delivery
  • Copies of used sources
  • Expert Proofreading
Paper format
  • 275 words per page
  • 12 pt Arial/Times New Roman
  • Double line spacing
  • Any citation style (APA, MLA, Chicago/Turabian, Harvard)

Our guarantees

Delivering a high-quality product at a reasonable price is not enough anymore.
That’s why we have developed 5 beneficial guarantees that will make your experience with our service enjoyable, easy, and safe.

Money-back guarantee

You have to be 100% sure of the quality of your product to give a money-back guarantee. This describes us perfectly. Make sure that this guarantee is totally transparent.

Read more

Zero-plagiarism guarantee

Each paper is composed from scratch, according to your instructions. It is then checked by our plagiarism-detection software. There is no gap where plagiarism could squeeze in.

Read more

Free-revision policy

Thanks to our free revisions, there is no way for you to be unsatisfied. We will work on your paper until you are completely happy with the result.

Read more

Privacy policy

Your email is safe, as we store it according to international data protection rules. Your bank details are secure, as we use only reliable payment systems.

Read more

Fair-cooperation guarantee

By sending us your money, you buy the service we provide. Check out our terms and conditions if you prefer business talks to be laid out in official language.

Read more
Open chat
1
You can contact our live agent via WhatsApp! Via + 1 929 473-0077

Feel free to ask questions, clarifications, or discounts available when placing an order.

Order your essay today and save 20% with the discount code GURUH