\documentclass[11pt]{article}

\author{Jeremy Morris}
\title{Chapter 2 Homework}

\usepackage{times,longtable,amssymb,amsmath,amsfonts}
\usepackage[T1]{fontenc}
\usepackage[dvips]{graphicx}
\addtolength{\hoffset}{-1.05cm}
\addtolength{\textwidth}{2.5cm}
\addtolength{\textheight}{2.5cm}

\begin{document}
\maketitle

\begin{table}[ht]
\begin{center}
\begin{tabular}{l|llllllllll|l|l}
year($i$) & \multicolumn{10}{|c|}{observations ($j$)} & $T_{i\cdot}$ & $s_{i\cdot}^{2}$ \\ \hline
1968 & 5.0 & 4.9 & 5.9 & 5.0 & 7.2 & 7.0 & 4.9 & 6.4 & 6.3 & 7.3 & 59.9 & 0.9788\\
1969 & 5.4 & 3.3 & 4.5 & 5.5 & 5.0 & 7.6 & 7.6 & 6.4 & 5.3 & 7.1 & 57.7 & 1.9557\\
1970 & 4.3 & 5.1 & 4.0 & 6.0 & 4.4 & 4.6 & 4.8 & 6.4 & 5.2 & 4.3 & 49.1 & 0.6077\\
1971 & 5.2 & 7.8 & 3.0 & 5.0 & 5.8 & 4.0 & 4.5 & 4.4 & 4.4 & 3.9 & 48.0 & 1.7000\\
1972 & 5.0 & 5.8 & 6.6 & 4.1 & 3.8 & 4.5 & 3.8 & 4.5 & 5.3 & 3.8 & 47.2 & 0.9040
\end{tabular}
\end{center}
\caption{Highway Safety Data}\label{data}
\end{table}

\begin{enumerate}
\setcounter{enumi}{1}
\item \textit{A government committee on highway safety was interested in whether roads were getting safer.  Ten states were randomly selected out of the 48 contiguous states and, for each of the years 1968 through 1972, the fatality rate (= deaths per 100 million vehicle miles) was calculated. This data is shown in Table \ref{data}}
	\begin{enumerate}
	\item \textit{Use each of the three tests for homogeneity on this data.  For consistency in calculating the $\ln{s^{2}}$ ANOVA test, use the first five and the last five observations in each state.}

	\input{homogeneity.tex}
	These tests indicate that we cannot reject the hypothesis that the data is homogenous.

	\item \textit{Test for the normality of the data collected in 1970.}

	\input{normal70.tex}
	These tests agree that the null hypothesis that the data is normally distributed cannot be rejected.  The data does not need to be transformed.

	\item \textit{Run an ANOVA on this data}.

	\input{anovatable.tex}

	\item \textit{Is there a significant difference in fatality rates using $\alpha = 0.05$?}

	Yes, there is a difference.
	\end{enumerate}

\item \label{three}
	\begin{enumerate}
	\item \textit{For the data listed in Table \ref{data}, what is the state to state (also called within year or error) standard deviation}

	$\sigma = \sqrt{MSE} = \sqrt{1.2292} = 1.1087$

	\item \textit{Assuming $\beta = 0.10$, what is the minimal difference in the annual death rate that can be detected with this data?}

	\[\delta = \sigma \Delta = 2.051\]  Where $\Delta$ is determined from the table in Appendix 10 with five treatments and ten repeats.
	
	\end{enumerate}


\item \textit{Use Duncan's test on the data in Table \ref{data} to determine which years differ.  Interpret the results.  Are the results consistent with question \ref{three}?  Why or why not?}

\input{duncan.tex}
These results are not inconsistent with the the answer for question \ref{three}.  What we see is Duncan's test detecting a smaller difference than the minimal difference we calculated in question \ref{three}.  This is because a difference smaller than $\delta = 2.051$ can be detected with probablility $< 0.90$.

\item \textit{Use orthogonal polynomials to find the order of the best fitting polynomial for the data in Table \ref{data}.  Give the ANOVA table in its final form.} 

The ANOVA and lack of fit tables follow :
\input{anovatable.tex}
\input{lackoffit.tex}
We conlude that there is a significant linear effect and there is not a significant lack of fit.  So we say that a linear trend adequately describes the data.


\end{enumerate}

\end{document}
