Starting from:

$35.99

MATH4387- Homework 4 Solved


Problem 1
Describe UN11 data in the alr4 package in your own words. You can get details using ?UN11 and googling things. Provide descriptive statistics and plots with your description.

Problem 2
Using the UN11 data set in the alr4 package:

a.    Fit a simple linear regression of y = log(fertility) on x=pctUrban.

data(UN11, package = 'alr4')

lm(log(fertility) ~ pctUrban, data = UN11)

##

## Call:

## lm(formula = log(fertility) ~ pctUrban, data = UN11)

##

## Coefficients:

## (Intercept)       pctUrban ##         1.50096 -0.01016

b.    Provide the equation for the fitted model.

Eˆ(log(fertility)|pctUrban) = 1.5 − 0.01pctUrban

c.    Use the model fit in a. to provide an interpretation of the association between pctUrban and fertility in the context of the problem.

For members of the United Nations, a 1 percent increase in the percentage of the population living in Urban regions is associated with an expected decrease in the number of children per woman by about 1% [the multiplicative effect is about exp(−0.01) ≈ 0.99].

Problem 3
Fit the regression of y = log(fertility) on x1 = log(ppgdp) and x2 = lifeExpF.

lm(log(fertility) ~ log(ppgdp) + lifeExpF, data = UN11)

##

## Call:

## lm(formula = log(fertility) ~ log(ppgdp) + lifeExpF, data = UN11)

##

## Coefficients:

## (Intercept)                 log(ppgdp)                lifeExpF

##             3.50736              -0.06544              -0.02824

1

a.    What is the equation for the fitted model?

Eˆ [log(fertility)|ppgdp, lifeExpF] = 3.5 − 0.065log(ppgdp) − 0.03(lifeExpF)

b.    If we increase ppgdp by 25%, what is the expected decrease in fertility?

The mean response should change by approximately a multiplicative effect of exp[−0.065log1.25] = 1.25−0.065 = 0.986. Thus, the fertility changes by about 100(0.986-1) = -1.4%.

c.    Using your computation from part b (i.e., for a 25% increase in ppgdp), provide an interpretation of the association between ppgdp and fertility in the context of the problem.

For members of the United Nations, a 25% increase in the per capita gross domestic product in US dollars is associated with an expected decrease in the number of children per woman of about 1.4%, assuming average life expectancy doesn’t change.

More products