\documentstyle[bj,times]{article}





\begin{document}


\frenchspacing

\input info.tex

\def\title{Breakout Exercise}

\pagestyle{myheadings}
\markboth{\title}{\title}
\makeatletter
%\def\@oddhead{\hbox{}\bf\leftmark \hfil \rightmark}
\def\@oddhead{\bf\rightmark\hfil\thepage}
\let\@evenhead\@oddhead
\newsavebox{\datebox}
\savebox{\datebox}{\llap{\term}{}}
\def\@oddfoot{\class\hfil\usebox{\datebox}}
\let\@evenfoot\@oddfoot
\makeatother

\begin{center}\Large\bf
\title
\end{center}

\section*{REM Latency in Depressed Patients}

The data for this problem comes from a study comparing REM (rapid eye
movement) latency times, in minutes, for 19 depressed patients with
those for 20 healthy patients.  The goal is to determine whether REM
latency is a good indicator of depression.

The REM latency times (in minutes) for depressed patients were
\begin{verbatim}
Pat. no.:  1  2  3  4  5  6  7  8  9 10 11 12 13 14 15 16 17 18 19
REM lat.: 87  2 39  5 81 81 47  6 10 25 65 48 15 21 52 17 48 19 48
\end{verbatim}
and for healthy patients they were
\begin{verbatim}
Pat. no.:  1  2  3  4  5  6  7  8  9 10 11  12 13 14 15 16  17 18 19 20
REM lat.: 47 90 95 51 87 60 69 51 19 54 66 138 64 66 60 84 137 60 69 63
\end{verbatim}

Look over the next several pages of summary information about this
data, and on the last page,
\begin{itemize}
\item Write down any conclusions or impressions you get from these summaries.
\item Answer the question: Is REM Latency a good predicttor of
  depression?   Justify your answer.
\end{itemize}

We have the following graphical information:
{\small
\begin{verbatim}
  Depr    -
          -    *
          -
        80+               *  *
          -
          -
          -
          -                                *
        60+
          -
          -                                            *
          -                     *             *              *    *
          -
        40+          *
          -
          -
          -
          -                              *
        20+                                         *          *
          -                                      *        *
          -                           *
          -                        *
          -       *    *
         0+
            +---------+---------+---------+---------+---------+------PatNo
          0.0       3.5       7.0      10.5      14.0      17.5

          Depressed patients' REM latencies (min) vs. patient number.

\end{verbatim}
}

\clearpage

{\small

\begin{verbatim}
 
          -
  Hlth    -                                 *              *
          -
          -
       120+
          -
          -
          -
          -        *
        90+     *       *
          -                                             *
          -
          -                   *                                 *
          -                              *     *  *                *
        60+                *                         *       *
          -          *           *     *
          -  *
          -
          -
        30+
          -
          -                         *
          -
          -
            --------+---------+---------+---------+---------+--------PatNo
                  3.5       7.0      10.5      14.0      17.5

           Healthy patients' REM latencies (min) vs. patient number.



\end{verbatim}
}

{\small
\begin{verbatim}
 Stem-and-leaf of Depr      N  = 19   Stem-and-leaf of Hlth      N  = 20
 Leaf Unit = 1.0                      Leaf Unit = 1.0
 
     3    0 256                            1    1 9
     7    1 0579                           1    2 
     9    2 15                             1    3 
    (1)   3 9                              2    4 7
     9    4 7888                           5    5 114
     5    5 2                             (9)   6 000346699
     4    6 5                              6    7 
     3    7                                6    8 47
     3    8 117                            4    9 05
                                           2   10 
                                           2   11 
                                           2   12 
                                           2   13 78

Distribution of patients' REM latency times.



\end{verbatim} 
}

{\em\small
\begin{verbatim}
 REM latency times      
 
                 ---------------
 Depr       -----I         +   I---------------
                 ---------------
 
                                  ------------
 Hlth              ---------------I  +       I----                *
                                  ------------
           +---------+---------+---------+---------+---------+------Latency
           0        25        50        75       100       125

Comparison of depressed and healthy patients---Parallel Box Plots.

\end{verbatim}
}

{\small
\begin{verbatim}
                  Group    Min     QL    Median     QH     Max
                  Depr    2.00   15.00    39.00   52.00   87.00
                  Hlth   19.00   55.50    65.00   86.25  138.00
\end{verbatim}
}

Put your answers here:

\clearpage

\section{REM Latency in Depressed Patients: A Good Solution}

The data for this problem comes from a study comparing REM (rapid eye
movement) latency times, in minutes, for 19 depressed patients with
those for 20 healthy patients.  The goal is to determine whether REM
latency is a good indicator of depression.

\comment{

The REM latency times (in minutes) for depressed patients were
\begin{verbatim}
Pat. no.:  1  2  3  4  5  6  7  8  9 10 11 12 13 14 15 16 17 18 19
REM lat.: 87  2 39  5 81 81 47  6 10 25 65 48 15 21 52 17 48 19 48
\end{verbatim}
and for healthy patients they were
\begin{verbatim}
Pat. no.:  1  2  3  4  5  6  7  8  9 10 11  12 13 14 15 16  17 18 19 20
REM lat.: 47 90 95 51 87 60 69 51 19 54 66 138 64 66 60 84 137 60 69 63
\end{verbatim}

}

A scatter plot of the REM latency time vs. patient number for depressed 
patients (\fig{1}) shows that the middle of the distribution of times is
around 40 minutes, but there are large changes in the variability as a
function of patient number---the times are much more variable for the
first few patients than for later patients.  

\begin{figure}[ht]
\small
\begin{verbatim}
  Depr    -
          -    *
          -
        80+               *  *
          -
          -
          -
          -                                *
        60+
          -
          -                                            *
          -                     *             *              *    *
          -
        40+          *
          -
          -
          -
          -                              *
        20+                                         *          *
          -                                      *        *
          -                           *
          -                        *
          -       *    *
         0+
            +---------+---------+---------+---------+---------+------PatNo
          0.0       3.5       7.0      10.5      14.0      17.5
\end{verbatim}
\normalsize
\caption{Depressed patients' REM latencies (min) vs. patient number.}
\label{1}
\end{figure}

\begin{figure}[ht]
\small
\begin{verbatim}
 
          -
  Hlth    -                                 *              *
          -
          -
       120+
          -
          -
          -
          -        *
        90+     *       *
          -                                             *
          -
          -                   *                                 *
          -                              *     *  *                *
        60+                *                         *       *
          -          *           *     *
          -  *
          -
          -
        30+
          -
          -                         *
          -
          -
            --------+---------+---------+---------+---------+--------PatNo
                  3.5       7.0      10.5      14.0      17.5
\end{verbatim}
\normalsize
\caption{Healthy patients' REM latencies (min) vs. patient number.}
\label{2}
\end{figure}
 
One possible reason for this change in variability is ``learning'' by the 
medical technician recording the times.  If this is the case, then perhaps 
in future experiments the technician should be trained on a few patients
to begin with, and then record ``live'' data for the experiment, to get
more consistent readings.

Note that in \fig{1} the depressed patients' REM latency times can
also be separated into two groups---one group with REM latencies
around 20 minutes, and another group around 50 minutes.  This suggests
that perhaps there are two types of depressed patient---a
low-REM-latency group and a high-REM-latency group.

A plot of REM latency time vs. healthy patient number (\fig{2}) shows
that the middle of the distribution of times is around 60 or 70, and
that there is less change in variability across patients.  However,
three observations, with times 19, 137 and 138, do not group well with
the others and may represent outliers.

Back-to-back stem and leaf diagrams of the two groups of patients are
shown in \fig{4}.

The distribution of depressed patients' REM latencies appears to be
bimodal, with a mode in the the upper 10--20 minute range and another
in the upper 40--50 minute range.  This distribution also appears to
be somewhat skewed to the right (long tail to the right).  Again,
there are no really clear outliers among depressed patients.

The distribution of healthy patients appears to be unimodal (mode in
the high 60's) and symmetric or again slighltly skewed to the right.
Again the latency times 19, 137 and 138 may be outliers, with 137 and
138 looking more extreme than 19.  Note that if the two suspected
outliers 137 and 138 were removed, the distribution would look skewed
to the left (longer tail to the left).

The two modes in the stem and leaf plot for the depressed patients
show again that it may be possible to separate depressed patients into
two groups: a low-REM-latency group with latencies of around 20
minutes; and a high-REM-latency group with latencies nearer to 60
minutes, which is more like the healthy REM latencies.  This should be
brought to the attention of the medical researchers: perhaps these two
groups will respond to different types of treatment for depression.
This also suggests that a test for depression based on REM latency
alone may not catch all depressed patients---the high-REM-latency
group will be missed.

\begin{figure}[ht]
\small
\begin{verbatim}
                           652| 0|
                          9750| 1|9
                            51| 2|
                             9| 3|
                          8887| 4|7
                             2| 5|114
                             5| 6|000346699
                              | 7|
                           711| 8|47
                              | 9|05
                              |10|
                              |11|
                              |12|
                              |13|78
                         -----+--+-----
                         Depr |  | Hlth
\end{verbatim}
\normalsize
\caption{Comparison of depressed and healthy patients---Back-to-back
Stem and Leaf Diagrams.}
\label{4}
\end{figure}

\comment{

\begin{figure}[hbp]
\small
\begin{verbatim}
 Stem-and-leaf of Depr      N  = 19   Stem-and-leaf of Hlth      N  = 20
 Leaf Unit = 1.0                      Leaf Unit = 1.0
 
     3    0 256                            1    1 9
     7    1 0579                           1    2 
     9    2 15                             1    3 
    (1)   3 9                              2    4 7
     9    4 7888                           5    5 114
     5    5 2                             (9)   6 000346699
     4    6 5                              6    7 
     3    7                                6    8 47
     3    8 117                            4    9 05
                                           2   10 
                                           2   11 
                                           2   12 
                                           2   13 78
\end{verbatim} 
\normalsize
\caption{Distribution of patients' REM latency times.}
\label{3}
\end{figure}

}

The mean REM latency for depressed patients is 37.68 and the standard
deviation is 27.27.  The mean for heathy patients is 71.50 and the
standard deviation is 28.20.  The difference in means also suggests
that the two groups are different, but the two possible outliers 137
and 138 are inflating the mean (and the standard deviation too) of the
healthy patients, so the evidence of the means alone is not very
convincing.

The back to back stem and leaf plots in \fig{4} give a better comparison
of the two distributions of REM latencies.  REM latency times
for depressed patients are generally much lower than for healthy
patients, although there is definitely some overlap.  Dotplots for the
two groups (not shown) give the same impression.

Now let's consider boxplots for the two groups, graphed on the same
latency (time) scale (\fig{5}).
\begin{figure}[hb]
\small
\begin{verbatim}
 REM latency times      
 
                 ---------------
 Depr       -----I         +   I---------------
                 ---------------
 
                                  ------------
 Hlth              ---------------I  +       I----                *
                                  ------------
           +---------+---------+---------+---------+---------+------Latency
           0        25        50        75       100       125
\end{verbatim}
\normalsize
\caption{Comparison of depressed and healthy patients---Parallel Box Plots.}
\label{5}
\end{figure}
The boxplot for depressed patients' latencies has a longer tail to the
right (skewed right), suggesting that the distribution is overall skewed
right.  The boxplot for healthy patients shows that the two observations
137 and 138 (represented by the {\tt *}) are outliers according to the
``{\tt 1.5*IQR}'' rule, and if they are omitted the distribution has a
longer tail to the left (skewed left).  These observations are
consistent with the stem and leaf diagrams in \fig{4}.

The outlying observations 137 and 138 should be brought to the
attention of the medical researchers, and investigated.  They may
represent some other sleeping disorder not related to depression.  Or
they may simply be mis-coded data: could the correct observations have
been 37 and 38, which would be more consistent with the rest of the
healthy patients' REM latencies?

The impression that the two groups are separate is even stronger with
the boxplots in \fig{5} than with the back-to-back stem and leaf plot
in \fig{4}.  The 5 number summaries for the two distributions are:

\clearpage

\begin{verbatim}
                  Group    Min     QL    Median     QH     Max
                  Depr    2.00   15.00    39.00   52.00   87.00
                  Hlth   19.00   55.50    65.00   86.25  138.00
\end{verbatim}

\comment{

The medians (39.00 and 65.00) are similar to the means (37.68 and
71.50); note that the mean healthy REM latency is much higher, due
mostly to the outliers 137 and 138.  The two IQR's
(52.00$-$15.00$=$37.00 and 86.25$-$55.50$=$30.75) are more similar to
the standard deviations (27.27 and 28.20).

}

Note, from the numbers or from \fig{5}, that the {\em lower\/}
quartile $Q_L$ for healthy patients is above the {\em upper\/}
quartile $Q_H$ for the depressed patients.  Thus, 75\% of the healthy
REM latencies are above 75\% of the depressed REM latencies.  A
reasonable guess as to who is depressed and who is healthy might come
from separating patients according to a REM latency time of about 53
minutes.  Note that this would not be perfect however: 25\% of each
group would be mis-classified according to this rule; and remember
that the depressed patients seem to belong to two separate groups, one
of which looks much more like healthy patients.  So some other test
will be needed as well, to distinguish depressed and healthy patients.

\section{REM Latency in Depressed Patients: A Bad Solution}

\noindent
Group 1: mean$=$37.68, standard deviation$=$30.75.  Distribution skewed
right.

\noindent
Group 2: mean$=$71.50, standard deviation$=$28.20.  Distribution
slightly skewed right.

\noindent
71.50$>$37.68, so there's a difference.  \minitab{} output
attached\footnote{(Raw computer output omitted from this example to save
paper! --BJ)} on separate pages.

\clearpage

\section{Comparison of the Two Solutions}

\subsection{The good solution}

Your solutions to data analysis exercises may only be 1/2 or 1/3 as
long as this idealized ``good solution''.  But you should still use
this as a model of the style and rough content for homework problems.
Try to include the following features in your writeups.

\begin{itemize}

\item Subject matter (REM latency times in depressed and healthy patient)
clearly stated.  {\em Subject matter plays an important role\/}
throughout the writeup and interpretation of results.  This is
absolutely crucial.

\item The analysis uses {\em multiple views of the data\/}:
\begin{itemize}
\item Time series plots (REM latency vs. patient number)
\item Stem and leaf diagrams
\item Boxplots
\item Numerical summaries
\end{itemize}
The different views confirm some patterns which don't show up well in
just one view.  They also reveal things (unusual REM latencies that
might be data recording errors, more than one group of depressed
patients, changing variability of REM latencies for depressed patients)
that can't be seen with numerical summaries alone.

\item {\em The problem is discussed in clear English\/} sentences and
paragraphs.

\item {\em Patterns and outliers are identified, if present\/}; possible
interpretations are given for them, and actions are suggested.

\item {\em All statements about the data are justified\/} by referring
to \minitab{} output.   All graphs shown have a clear purpose, are used
in the discussion, and are explained.

\item {\em Conclusions are based on all the evidence\/}, not just one
thing.

\end{itemize}


\subsection{The bad solution}

This solution is too brief, and is totally disconnected from the process
or problem from which we got the data.  It would probably get a zero on
a homework assignment.

\begin{itemize}

\item No statement of what the data are, why we are looking at them, or
how many observations there are.

\item No mention of outliers (or lack of outliers), or patterns in the
data (or lack of patterns).  No discussion of how outliers or patterns
might affect the results.

\item Insufficient statements about variability.

\item No justification for the statements about skewness.

\item No reference to or interpretation of computer output.

\item No statement about the meaning or relevance of the results.

\end{itemize}

\end{document}

