Uploaded by jusmanjuspin3

PRACTICAL 1 (REGRESSION) BS21110032

advertisement
NAME: MOHAMAD KAHIRUL BIN MOHAMMADKAN
MATRIX.NO: BS21110032
SV30602 FOUNDATION OF MACHINE LEARNING, SEMESTER 2 SESSION 2023/2024
REGRESSION ANALYSIS
PRACTICAL 1
a) Show the output produced as shown on Page 46 for the regression analysis.
b) Show the output produced as shown on Page 48 for the regression analysis
c) Perform a regression analysis for the charges variable using the following independent
variables (predictors)
i. Age
ii. Age and BMI
iii. Age, BMI, and Children
iv. Age, BMI, Children and Smokers
d) Determine which one is the best model based on the R2 value.
Age, BMI, Children and Smokers is the best model based on R2 value, cause it has 0.7497
multiple R-squared value, which is greater than other model. Higher R-squared values means
the model is better.
e) Which model requires the lowest charges for each year that age increases?
Model: Age
The coefficient for age is 257.7. This means that for each year increase in age, the charges
are predicted to increase by $257.7, holding other variables constant. This is the lowest
increase in charges per year compared to the other models, indicating that this model predicts
the lowest charges for each year as age increases.
Download