MATH
Regression.pdf

# Source df sum of squares mean squares f pr f acetic 1

• 63

This preview shows pages 35–38. Sign up to view the full content.

Source DF Sum of Squares Mean Squares F Pr > F ACETIC 1 0.56 0.56 0.0054 0.9419 H2S 1 1007.69 1007.69 9.8187 0.0042 LACTIC 1 533.26 533.26 5.1959 0.0311 The Lack of Fit Test When we want to determine whether a specified regression function adequately fits the data, we can conduct a lack of fit test. However, it is important to note that the test requires repeated observations (replications) for at least one of the values of the predictors ( X ). This test is also based on decomposing sums of squares (due to Errors) and the test procedure can be derived in the same way as testing the full vs. reduced model. F = (SSLF SSPE) / ( n p ( n c )) MSPE where p is the number of regression parameters and c is the number of distinct X values, SSLF denotes the lack of fit sum of squares, and SSPE (thus, MSPE for mean squares) stands for the sum of squares due to pure error. PAGE 35

This preview has intentionally blurred sections. Sign up to view the full version.

2.3 Qualitative Independent Variables c circlecopyrt HYON-JUNG KIM, 2017 2.3 Qualitative Independent Variables Types of variables Qualitative variables : Numerical measurements on the phenomena of interest are not possible. Rather, the observations are categorical. e.g. gender (female, male), Company status (private, public), Treatment (yes, no), blood pressure rating (low, average, high) Quantitative variables: The observations are in the form of numerical values. e.g. age, income, temperature, number of defectives, etc. Qualitative or “classification” variables can be included as explanatory variables in regression models by using indicator variables (also called ‘dummy’ or ‘binary’ variables). Example: On average, do smoking mothers have babies with lower birth weight? Response ( Y ): birth weight in grams of baby X 1 : length of gestation in weeks, X 2 : Smoking status of mother (smoker or non-smoker) Then, a first order model with one binary and one quantitative predictor appears to be a natural model to formulate for these data: Y i = β 0 + β 1 X i 1 + β 2 X i 2 + ǫ i , where X i 2 = 1 if mother i smokes 0 otherwise Q. Why not just fit two separate regression functions one for the smokers and one for the non-smokers? The combined regression model assumes that the slope for the two groups are equal and that the variances of the error terms are equal. Then, it is better to use as much data as possible to estimate standard errors of regression coefficients for testing and confidence intervals. Pooling your data and fitting the combined regression function allows you to easily and efficiently answer research questions concerning the binary predictor variable. PAGE 36
2.3 Qualitative Independent Variables c circlecopyrt HYON-JUNG KIM, 2017 Example. If we are interested in quantifying the relationship between total population (of a metropolitan area) and number of active physicians it may be important to take (4) geographic regions into account. The indicator variables can be easily used to identify each of 4 regions as follows: X 1 = 1 if region 1 0 otherwise X 2 = 1 if region 2 0 otherwise X 3 = 1 if region 3 0 otherwise X 4 = 1 if region 4 0 otherwise

This preview has intentionally blurred sections. Sign up to view the full version.

This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

### What students are saying

• As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

Kiran Temple University Fox School of Business ‘17, Course Hero Intern

• I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

Dana University of Pennsylvania ‘17, Course Hero Intern

• The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

Jill Tulane University ‘16, Course Hero Intern