Question

In: Statistics and Probability

You will be using your Framingham dataset for the following questions. 7. Calculate a multivariable regression...

You will be using your Framingham dataset for the following questions.

7. Calculate a multivariable regression where the outcome is total serum cholesterol and the independent variables are BMI, age, sex and smoking status. Interpret.
8. Use the regression from question 7 to answer the following.
a. What is the predicted total serum cholesterol for a 50 year-old man who doesn’t smoke and whose BMI is 25?
b. What is the predicted total serum cholesterol for a 25 year-old woman who smokes and whose BMI is 32?

Solutions

Expert Solution

I have coded in R for the first part. The code is as follows:

> library(swgee)
> attach(framingham)

The following objects are masked from framingham (pos = 3):

age, bmi, BPVar, cigpday, cursmoke, female, glucose, heartrte,
outcome, time_outcome, totchol

The following objects are masked from framingham (pos = 4):

age, bmi, BPVar, cigpday, cursmoke, female, glucose, heartrte,
outcome, time_outcome, totchol

The following objects are masked from framingham (pos = 5):

age, bmi, BPVar, cigpday, cursmoke, female, glucose, heartrte,
outcome, time_outcome, totchol

The following objects are masked from framingham (pos = 6):

age, bmi, BPVar, cigpday, cursmoke, female, glucose, heartrte,
outcome, time_outcome, totchol

The following objects are masked from framingham (pos = 7):

age, bmi, BPVar, cigpday, cursmoke, female, glucose, heartrte,
outcome, time_outcome, totchol

The following objects are masked from framingham (pos = 8):

age, bmi, BPVar, cigpday, cursmoke, female, glucose, heartrte,
outcome, time_outcome, totchol

The following objects are masked from framingham (pos = 9):

age, bmi, BPVar, cigpday, cursmoke, female, glucose, heartrte,
outcome, time_outcome, totchol

The following objects are masked from framingham (pos = 10):

age, bmi, BPVar, cigpday, cursmoke, female, glucose, heartrte,
outcome, time_outcome, totchol

> data=framingham
> LinMod=lm(totchol~bmi+age+female+cursmoke,data)
> summary(LinMod)

Call:
lm(formula = totchol ~ bmi + age + female + cursmoke, data = data)

Residuals:
Min 1Q Median 3Q Max
-112.139 -27.323 -3.522 24.073 244.440

Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 116.6729 8.4932 13.737 < 2e-16 ***
bmi 1.4556 0.2544 5.721 1.2e-08 ***
age 1.5196 0.1048 14.502 < 2e-16 ***
female 5.7306 1.7463 3.281 0.00105 **
cursmoke 4.3192 1.7528 2.464 0.01381 *
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

Residual standard error: 40.04 on 2311 degrees of freedom
Multiple R-squared: 0.09854, Adjusted R-squared: 0.09698
F-statistic: 63.15 on 4 and 2311 DF, p-value: < 2.2e-16

> LinMod

Call:
lm(formula = totchol ~ bmi + age + female + cursmoke, data = data)

Coefficients:
(Intercept) bmi age female cursmoke
116.673 1.456 1.520 5.731 4.319

Thus, the linear model is:
totchol =   116.673 +1.456*bmi+1.520*age+5.731*female+4.319*cursmoke

Now, the given values are:

bmi age female cursmoke
sample1 25 50 1 0
sample2 32 25 1 1


Thus, the first prediction is:

totchol =   116.673 +1.456*25+1.520*50+5.731*1+4.319*0
= 234.804

The second prediction is:
totchol =   116.673 +1.456*32+1.520*25+5.731*1+4.319*1
= 211.315

PS. If you do find the dataset under swgee, it will be under LocalControl

I hope this clarifies your doubt. If you're satisfied with the solution, hit the Like button. For further clarification, comment below. Thank You. :)


Related Solutions

You will be using your Framingham dataset to answer the following questions. You will be performing...
You will be using your Framingham dataset to answer the following questions. You will be performing hypothesis testing. For each question, please write out the null hypothesis, alternate hypothesis, which test statistic you will be using (based on variable type). Then report the results from performing the analysis using SPSS. Make sure to report the test statistic, significance level, and whether you will accept or reject the null hypothesis and why. Finally, if you find significant differences, report the proper....
b. Write down potential questions that you could answer using regression analysis for the Happiness_2011.xls dataset...
b. Write down potential questions that you could answer using regression analysis for the Happiness_2011.xls dataset c. Perform one simple regression using any two reasonable variables from the Happiness_2011.xls file (two quantitative variables) and show the analysis result d. Interpret the findings from the simple regression analysis e. Add one or more quantitative variable (including dummy variable that have values of 0 and 1) to the analysis in #b, perform one multiple regression analysis f. Interpret your findings from the...
Use the dataset and the predicted regression equation to calculate the expected value of Y for...
Use the dataset and the predicted regression equation to calculate the expected value of Y for each known value of X. Then, use this information to calculate the standard error of estimate. Round all values to the nearest whole number. Y’ = 2.5 + .75(ice cream sales) Ice Cream Sales Observed Crime Predicted Crime 10 5 20 20 30 30 20 25 30 15 10 10 Now, calculate the standard error. The standard error is _________ PLEASE show your work...
Using the mtcars dataset, answer the following questions: Fill in the following table: Variable Correlation with...
Using the mtcars dataset, answer the following questions: Fill in the following table: Variable Correlation with mpg cyl -0.85216 disp -0.84755 hp -0.77617 drat 0.681172 wt -0.86766 qsec 0.418684 vs 0.664039 am 0.599832 gear 0.480285 carb -0.55093 mpg cyl disp hp drat wt qsec vs am gear carb Mazda RX4 21 6 160 110 3.9 2.62 16.46 0 1 4 4 Mazda RX4 Wag 21 6 160 110 3.9 2.875 17.02 0 1 4 4 Datsun 710 22.8 4 108...
Consider Dataset A for answering the questions that follows below. a. Calculate the measures of central...
Consider Dataset A for answering the questions that follows below. a. Calculate the measures of central tendencies for Variable X and Variable Y. i. Mean ii. Median iii. Mode iv. Midrange v. What can you say about the skewness of X and Y variables? b. Calculate the measures of variations for Variable X and Variable Y. i. Range ii. Variance iii. Standard Deviation iv. Coefficient of Variation v. Which is more variable, X or Y? Why? c. Calculate the measures...
How do I upload the Dataset in order for you to answer the following questions? Generate...
How do I upload the Dataset in order for you to answer the following questions? Generate a bivariate display in SPSS or PSPP for the DEGREE variable with each of the other attitude variables (you will have two tables). Then answer the questions below. Q3a: The majority of those with a Graduate degree reported what level of confidence in the military? Report the category for conarmy and the associated percentage. Category _______________ Percentage_____________
6. Discrete probability distributions #2 You may calculate the answers of the following questions using the...
6. Discrete probability distributions #2 You may calculate the answers of the following questions using the equations in your textbook for the appropriate probability distribution function. (You will need to read the questions first to determine the appropriate distribution.) However, you may also determine these answers by using the Distributions tool. Select the appropriate distribution from the dropdown box in the upper left-hand corner. Set the parameters accordingly, and select the radio button in the lower left-hand corner depending on...
Examine classification using logistic regression. In R console, type mtcars. The dataset mtcars is a generic...
Examine classification using logistic regression. In R console, type mtcars. The dataset mtcars is a generic dataset in R. This dataset comprises of fuel consumption and 10 aspects of automobile design and performance for 32 automobiles. Using only the variables am (0 = automatic, 1 = manual) and mpg, your task is to fit a logistic regression model. Complete the following steps using R. Create a scatter plot of am vs. mpg. Describe the relationship and explain why a simple...
Please answer this using Rstudio For the oyster data, calculate regression fits (simple regression) for the...
Please answer this using Rstudio For the oyster data, calculate regression fits (simple regression) for the 2D and 3D data a.1) Give null and alternative hypotheses a.2) Fit the regression model a.3) Summarize the fit and evaluation of the regression model (is the linear relationship significant). a.4 )Calculate residuals and make a qqplot. Is the normal assumption reasonable? Actual   2D   3D 13.04   47.907   5.136699 11.71   41.458   4.795151 17.42   60.891   6.453115 7.23   29.949   2.895239 10.03   41.616   3.672746 15.59   48.070   5.728880 9.94  ...
Use this information to answer the questions below: A regression has been run for you using...
Use this information to answer the questions below: A regression has been run for you using the SAS and the following regression equation was obtained: Y = 30-2X + U. The following data are given to you for your use in analyzing the assumptions about the OLS model. Obs Y X (X-) (Y-) (X-)(Y-) (X-)2 (Y-)2 U U2 u(-1) X2 1 10 4 2 50 3 3 10 2 4 30 1      1 Give the problem which is caused...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT