The name is absent



Stata Technical Bulletin


35


5.

M

M

6.

M

M

7.

M

M

8.

M

M

9.

M

M

10.

M

M

Each observation corresponds to one of the 747 individuals and records that individual’s genotype; the al variable holds
the value of the first allele, and the a2 variable that of the second allele.

We now perform the test for Hardy-Weinberg equilibrium.

. genhw al a2

Genotype Observed        Expected

------------+-----------------------------

MM I           233           242.37

MN I           385           366.26

NN I           129           138.37

total

I             747

747.00

Allele

I Observed

Frequency      Std. Err.

M

I        851

0.5696         0.0125

N

I        643

0.4304         0.0125

total

I      1494

1.0000

Estimated disequilibrium coefficient (D) = -0.0125

Hardy-Weinberg Equilibrium Test :

Pearson chi2 (1) =    1.956 Pr= 0.1620

likelihood-ratio chi2 (1) =    1.959 Pr= 0.1616

Exact significance prob =               0.1793

The command first tabulates the observed and expected (under HW) genotype frequencies, the allele frequencies, and
corresponding estimated standard errors. Then it calculates Pearson’s and the likelihood-ratio chi-squared statistics, and in the
case of a biallelic locus, an exact significance probability is also reported.

For these data all three Hardy-Weinberg tests agree. They are not statistically significant; therefore, we fail to reject the
null hypothesis that the population is in Hardy-Weinberg equilibrium.

We also obtained an estimate of the disequilibrium coefficient (D). At Hardy-Weinberg equilibrium, the expected value of
the disequilibrium coefficient is zero.

An immediate form of the above command that will yield the same results is constructed using the observed genotype
counts:

. genhwi 233 385 129, label(MM MN NN)

The label () option is used to label the tables. The genhwi command expects the genotype counts to be ordered as shown
in the syntax diagram.

Because there is no statistical evidence that this population is not in Hardy-Weinberg equilibrium, we can rerun the command
specifying the binvar option producing binomial standard error.

genhw al a2, binvar

Genotype I

Observed

Expected

MM I

233

242.37

MN I

385

366.26

NN I

129

138.37

____________

total I

747

747.00

Allele

Observed

Frequency      Std. Err.

M I

851

0.5696         0.0128 (binomial)

N I

643

0.4304         0.0128 (binomial)

total I

1494

1.0000

Estimated disequilibrium coefficient (D) = -0.0125



More intriguing information

1. The Macroeconomic Determinants of Volatility in Precious Metals Markets
2. The Context of Sense and Sensibility
3. Dynamic Explanations of Industry Structure and Performance
4. Feature type effects in semantic memory: An event related potentials study
5. How we might be able to understand the brain
6. Neighborhood Effects, Public Housing and Unemployment in France
7. NEW DEVELOPMENTS IN FARM PRICE AND INCOME POLICY PROGRAMS: PART I. SITUATION AND PROBLEM
8. Une Classe de Concepts
9. EMU's Decentralized System of Fiscal Policy
10. The name is absent