Answer To: Sheet1 CarMPGWeightCylindersHorsepowerCountry Buick Skylark28.42670490U.S. Dodge...
Vishvajeet answered on Apr 07 2022
Engineering Department, UMass Boston Spring 2022
ENGIN 322: Probability and Random Processes
Project #2: Sampling Theory and Linear Regression
Name:……………………………………………… ID:………………………..
Name:……………………………………………… ID:……………………….
Table of Contents
Title Page
1
Objective
3
Introduction
3
Apparatus
3
Procedure
3
Results and Discussion
4-11
Conclusion
References
11
11
Objective: In this project, you will assume the part of an automotive manufacturer. In part I,
you will provide background analysis for the development of a new vehicle. In part II, you will
develop a method for sampling manufactured parts in order to determine the likelihood of
failure.
Introduction:
Regression analysis is an important statistical method for the analysis of data. By applying
regression analysis, we are able to examine the relationship between a dependent variable and
one or more independent variables. In this article, I am going to introduce the most common
form of regression analysis, which is the linear regression. As the name suggests, this type of
regression is a linear approach to modeling the relationship between the variables of interest.
Method
Linear regression is used to study the linear relationship between a dependent variable (y) and
one or more independent variables (X). The linearity of the relationship between the
dependent and independent variables is an assumption of the model. The relationship is modeled
through a random disturbance term (or, error variable) ε. The disturbance is primarily
important because we are not able to capture every possible influential factor on the dependent
variable of the model. To capture all the other factors, not included as independent variable, that
affect the dependent variable, the disturbance term is added to the linear regression model.
In this way, the linear regression model takes the following form:
where
are the regression coefficients of the model (which we want to estimate!), and K is the number
of independent variables included. The equation is called the regression equation.
Simple linear regression
Let’s take a step back for now. Instead of including multiple independent variables, we start
considering the simple linear regression, which includes only one independent variable. Here,
we start modeling the dependent variable yi with one independent variable xi:
where the subscript i refers to a particular observation (there are n data points in total). Here, β0
and β1 are the coefficients (or parameters) that need to be estimated from the data. β0 is the
intercept (a constant term) and β1 is the gradient.
In simple linear regression, we essentially predict the value of the dependent variable yi using
the score of the independent variable xi, for observation i.
Apparatus/Tools:
• Personal Computer or Laptop.
• MATLAB etc
Procedure:
Results and Discussion:
Part 1 –
a) Load the data set into Matlab with the readtable() function
b) Determine the data set correlation (i.e., Pearson’s r) for average mpg versus weight, number
of cylinders, and horsepower.
c) Use the scatter() and polyfit() functions to display the data points and linear regression curves
for average mpg versus weight, number of cylinders, and horsepower. For each of the 3 plots,
show average mpg on your Y axis. Label the resulting plots and include them in your report.
Part 2 –
Assume that you have received reports of faulty headlights. The data values in the file...