Create summary statistics for the hp column for cars

Assignment Help Computer Engineering
Reference no: EM133803700

Assignment: Programming for Business Analytics

We will use built-in datasets from R.
Dataset mtcars
Here's a brief overview of the variables included in the mtcars dataset:
mpg: Miles/(US) gallon
cyl: Number of cylinders
disp: Displacement (cubic inches)
hp: Gross horsepower
drat: Rear axle ratio
wt: Weight (1000 lbs)
qsec: 1/4 mile time
vs: V/S (V-engine or straight engine; here, it's a binary indicator, with '0' indicating a V-engine and '1' indicating a straight engine)
am: Transmission (0 = automatic, 1 = manual)
gear: Number of forward gears
carb: Number of carburetors

Create a new R script and paste the following script into R.

##-----This is the instruction-------------
#load dataset mtcars
data(mtcars)

#display the structure and head of the dataset
str(mtcars)
head(mtcars)

#choose 5 questions to answer from the questions below, please copy and paste the questions you choose into your r script. If you answer all the questions, Only the first 5 answers will be graded. Save your file frequently and submit it after completion.

1. Find cars with housepower(hp) greater than 120, and weight(wt) greater than 3.5

2. Create summary statistics for the "hp" column for cars with displacement(disp) greater than 110.

3. Find the mean of the variable mpg where cars with cylinders(cyl) > 4

4. Find the car which has highest displacement (disp)

5. create a scatter plot using ggplot2 to visualize the relationship between a car's weight (wt) and its miles per gallon (mpg) (hint: x=wt, y=mpg)

6. create a line graph that displays the relationship between the variables 'mpg' (miles per gallon) and 'disp' (displacement) (hint: x=disp, y=mpg)

7. create a boxplot that visualizes the distribution of hp (horsepower) for each number of cylinders (cyl) in the mtcars dataset.

8. Display the count of cars that are automatic (am == 0) Hint: is the count equal to the number of rows or columns?

Reference no: EM133803700

Questions Cloud

Discuss how the technology is trending in the workforce : Discuss how the technology is trending in the workforce and a potential security implication of the technology.
What is influence of technology on chosen field of study : What is influence of technology on your chosen field of study or future profession? How can you use your understanding of technology in your professional career
What did you consider important when making the choice : What strategy did you leverage to determine the correct device or technology? What did you consider important when making the choice?
How psychology society and biology play a role in topic : Describe how psychology, society, and biology play a role in your topic. How does nature/nurture play a role? What does the biopsychosocial model say?
Create summary statistics for the hp column for cars : BZAN 4397- Create summary statistics for the hp column for cars with displacement(disp) greater than 110. Find the car which has highest displacement.
Which do you think is more influential in the development : Which do you think is more influential in the development of eating disorder-media or direct social contacts? Which has more of an influence on you?
Does fact that gangs exist dictate that are of sufficient : Does the fact that gangs exist dictate that they are of sufficient importance to devote separate study to or should we just study gangs as yet another manifesta
Which gangs currently pose the greatest threat to society : Based on your readings, the videos provided in the LibGuide you have viewed so far. Discuss which gangs currently pose the greatest threat to society.
Define your key assumptions and limitations of your model : Define the target population and build a population funnel. Define your key assumptions and limitations of your model.

Reviews

Write a Review

Computer Engineering Questions & Answers

  Mathematics in computing

Binary search tree, and postorder and preorder traversal Determine the shortest path in Graph

  Ict governance

ICT is defined as the term of Information and communication technologies, it is diverse set of technical tools and resources used by the government agencies to communicate and produce, circulate, store, and manage all information.

  Implementation of memory management

Assignment covers the following eight topics and explore the implementation of memory management, processes and threads.

  Realize business and organizational data storage

Realize business and organizational data storage and fast access times are much more important than they have ever been. Compare and contrast magnetic tapes, magnetic disks, optical discs

  What is the protocol overhead

What are the advantages of using a compiled language over an interpreted one? Under what circumstances would you select to use an interpreted language?

  Implementation of memory management

Paper describes about memory management. How memory is used in executing programs and its critical support for applications.

  Define open and closed loop control systems

Define open and closed loop cotrol systems.Explain difference between time varying and time invariant control system wth suitable example.

  Prepare a proposal to deploy windows server

Prepare a proposal to deploy Windows Server onto an existing network based on the provided scenario.

  Security policy document project

Analyze security requirements and develop a security policy

  Write a procedure that produces independent stack objects

Write a procedure (make-stack) that produces independent stack objects, using a message-passing style, e.g.

  Define a suitable functional unit

Define a suitable functional unit for a comparative study between two different types of paint.

  Calculate yield to maturity and bond prices

Calculate yield to maturity (YTM) and bond prices

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd