Analysis of the heart weights of cats
联系我们: 手动添加方式: 微信>添加朋友>企业微信联系人>13262280223 或者 QQ: 1483266981
Analysis of the heart weights of cats
Introduction
Experiments were conducted as part of reseach into “Digitalis”, a heart medicine similar to toxins found in plants commonly known as foxglove. 144 domestic male and female adult cats were used in the experiments and they each had their heart weight in grams (Hwt) measured. This data, including the sex (Sex) of each cat, is analysed in this report.
In particular, this report presents numerical and graphical summaries of the heart weights of the cats and ts a linear model to estimate the di erence, on average, between the heart weights of male and female cats.
Exploratory Data Analysis
Summary statistics of the heart weights of the cats are presented in the following table for each sex separately.
Table 1: Summary statistics on heart weight by sex of 144 adult cats.
Sex
n
Mean
St.Dev
Min
Q1
Median
Q3
Max
F
47
9.2
1.4
6.3
8.35
9.1
10.1
13.0
M
97
11.3
2.5
6.5
9.40
11.4
12.8
20.5
Table 1shows that there were approximately twice as many male cats in the sample (97 compared to 47) and that the summaries of the heart weights of the male cats were consistently greater than the corresponding summaries of the heart weights of female cats. For example the mean heart weight of the male cats was 11.3 grams comared to 9.2 grams for the mean heart weight of cats. We also note that the variability in the male hearts’ weights, as measured by the standard deviation of 2.5 grams, was nearly twice as much as the standard deviation of 1.4 grams for the female hearts’ weights. These di erences can be easily seen in the following boxplots which summarise the distributions of the heart weights of male and female cats.
Heart weights of 144 adult cats
20
15
M
Sex
Figure 1: Heart weight by Sex.
The boxplot shows that the male cats having heavier hearts, in general, compared to the female cats’ hearts and that the weights of the male hearts were more widely distributed. There are also potentially two outliers (one male and one female) which have unusually heavy hearts, as shown by the two points shown beyond the “whiskers” of the boxplots.
Formal Data Analysis
To begin to analyse the cat heart weights data formally, we t the following linear model to the data.
H一wt; = + Male 3 』Male (;)
where
● H一wt; is the expected value of the heart weight of the ;th cat in the sample
● the intercept is the mean heart weight for the baseline category of females;
● Male is the di erence in the mean heart weight of a males relative to the baseline category females; and
● 』Male (;) is an indicator function such that
』Male (;) = , 0(1) O(if)ther(Sex)w(o)
When this model is tted to the data, the following estimates of a (intercept) and βMale (SexM) are returned:
Table 2: Estimates of the parameters from the tted linear regression model.
Term
Estimate
CI Lower Bound
CI Upper Bound
p value
intercept
9.202
8.560
9.845
0
Sex: M
2.121
1.338
2.904
0
Hence the model estimates the average heart weight of female cats is 9.202 grams (which agrees with the sample mean reported in Table 1) and that the male cats’ heart weights are, on average, 2.121 grams heavier than the female cats’ heart weights.
[NB: The instructions for the class test state that this section on assumption checking does not need to be included since the assumptions are supported, but it is included here for completeness]
Before we can proceed to use the tted model (for example to perform statistical inference) we must check the assumptions of the model. These are best considered in light of the residual plots in Figure 2.
5
0
5
M
F
Sex
15
10
5
0
5 0 5 10
Residual
Figure 2: Scatterplots of the residuals by Sex (left) and a histogram of the residuals (right).
The scatterplots show an approximately even spread of the residuals above and below the zero line for each gender, and hence the assumption that the residuals have mean zero appears valid. The assumption of constant variance within the two genders is not supported, however, as the spread of the residuals in the vertical scatter of the male cats is considerably more than that of the females (as was noted above when the standard deviations were considered). The histogram supports the assumption of normally distributed errors in the model, with the exception of a potential outlier.
Having explored the assumptions of the tted model, the con dence intervals and p-values reported in Table
2 can be interpreted (with caution in this case). The p-value associated with the SexM term is less than
0.05 and therefore supports a signi cant di erence between the mean heart weights of male and female cats (at the 5% level). The corresponding con dence interval estimates that the male heart weights are between 1.338 and 2.904 grams heavier than the mean female heart weights.
Conclusions
In summary, we have estimated that, on average, the male cats have hearts which weigh 2.121 grams more than the female cats’ hearts. In particular, we estimate the average heart weight of female cats is 9.202 grams and the average heart weight of male cats is 11.323 grams and this di erence is statistically signifcant and the 5% level.
In addition to the centers of the distibutions of male and female cats’ heart weights being di erent, we have also observed that the spread of the male heart weights is greater than the spread of the female cats’ heart weights. This may pose a problem if the standard linear model was used to further analyse this data, and therefore it is recommended that models which allow for di erences in the variances within di erent groups be used.


发表回复