HW8 2023
HW8 2023
HW8 2023
HOMEWORK 8
1) The daily growth of toe nails is influenced by a number of factors. Age is believed to be
one of them but in unexpected ways. Patrizia Schembri, a podologist researcher, was
interested to see whether there are differences in growth between nails on different fingers.
So she contacted a number of persons of varying ages and made daily measurements on the
first and second fingers of the right hand. The daily increase in millimeters for finger nails 1
and finger nails 2 as well as the age of the person whose fingers were measured and are
given in the table below for 48 different persons.
Using R, the following figures were calculated between age and growth of nails on
finger 1 and 2:
Correlation between Nail 1 and Age: -0.3486871
Correlation between Nail 2 and Age: 0.314817
Correlation between Nail 1 and Nail 2: 0.190562
Checking for significance at α = 0.05:
P-value for correlation between Nail 1 and Age: 0.01514622
P-value for correlation between Nail 2 and Age: 0.02930413
P-value for correlation between Nail 1 and Nail 2: 0.1945015
Comment:
The correlation between Nail 1 and age shows a significant relationship (p-value:
0.01514622), signifying that the growth of Nail 1 is correlated with age. Similarly,
Nail 2 shows a significant correlation with age (p-value: 0.02930413), indicating age-
related influences on the growth rate of Nail 2. Interestingly, the correlation
between Nail 1 and Nail 2 growth rates is not statistically significant (p-value:
0.1945015), suggesting that the growth rates of these nails are not correlated. This
means that age plays an important role in influencing the growth rates of toenails.
ii. From experience, Patrizia has noticed that it is differential rates of growth which
are really influenced by age. She has observed that the symmetry of the finger nails
is in fact changing considerably as a person gets older. So she has decided to see
how the variable Z = Y =Growth rate of Nail 1−Growth rate of Nail 2 varies with
Age. Perform a linear regression between these two variates and work out all the
necessary parameter estimates and statistics at the 5% level of significance.
[ 14 marks ]
Call:
lm(formula = z ~ corrdata$Age)
Residuals:
Min 1Q Median 3Q Max
-30.849 -8.248 -3.235 8.730 33.617
Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 17.80191 2.91886 6.099 2.06e-07 ***
corrdata$Age -0.28520 0.07002 -4.073 0.000181 ***
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
The linear regression model reveals a significant negative relationship between the
difference in growth rates of Nail 1 and Nail 2 (Z) and individuals' age (Estimate: -
0.28520, p-value: 0.000181). The intercept, 17.80191, represents the estimated
average Z when age is 0. The model explains 26.51% of Z's variability (R²: 0.2651).
The F-statistic is 16.59 with a p-value of 0.000181, indicating the model's overall
significance. Residuals have a standard error of 12.81, signifying the typical deviation
from the regression line. In simple words, age significantly influences the differential
growth rates of toenails, the model provides insights into this relationship.
2. The following readings pertain to employment in the hospitality industry, measured in
terms of number of employees in thousands, within the economy of the KamTam Republic.
i. Establish that there is a linear trend in the figures and estimate it, together with all
accompanying statistics suitably reported and commented.
SUMMARY
OUTPUT
Regression Statistics
0.38890453
Multiple R 9
R Square 0.15124674
Adjusted R 0.13279558
Square 3
Standard
Error 22.9546011
Observations 48
ANOVA
Significance
df SS MS F F
0.00629810
Regression 1 4319.186 4319.186 8.197141 9
Residual 46 24238.03 526.9137
Total 47 28557.22
Seasonalit
Month y
0.96626 0.96136 0.95832 0.96251
Jan 3 2 2 7 0.962116
0.97473 0.97481 0.96801 0.96929
Feb 4 6 4 7 0.971715
0.98818 0.98726 0.97903 0.97881
Mar 1 4 5 8 0.983324
0.99427 1.00895 0.99629 0.98992
Apr 3 9 1 2 0.997361
1.00388 1.02289 1.00513 1.00668
May 8 8 9 1 1.009652
1.01665 1.03170 1.01130 1.01731
June 9 1 2 3 1.019243
1.02570 1.03070 1.01915 1.01572
Jul 6 7 1 3 1.022822
1.02796 1.03321 1.01997
Aug 3 4 1.01942 1 1.025142
1.01955 1.02379 1.01265 1.01608
Sep 9 3 7 5 1.018024
0.99907 1.00479 0.99291 0.99719
Oct 1 7 7 2 0.998494
0.99619 0.98866 0.99120
Nov 8 1.0023 8 6 0.994593
0.99747 1.00437 0.98851 0.99969
Dec 6 1 1 2 0.997512