%% dbp-letterhead.sty
%\usepackage[fleqn]{amsmath}
%\usepackage{amssymb}
%\usepackage{amsfonts}
%\usepackage{graphicx}
\usepackage{graphicx}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
%\usepackage[usenames]{pstricks}


\def\letterhead{%
\bgroup
%\noindent
\ 
%\vskip-4.3in
%\vskip-1.3in
\vskip-0.68in
%\hskip-1.8in

%\boxed{
\hbox to \paperwidth{\hskip-0.75in\includegraphics[width=6.52in]{StatisticsLetterhead.pdf}
\hss}
\egroup
}

\def\letterhead{%
\bgroup
\setlength{\voffset}{-1in}%
\setlength{\headheight}{0pt}%

%\vskip-1.3in\hrule

%\noindent
\ 
%\vskip-4.3in
\vskip-1.2in
%	\vskip-0.68in
%\hskip-1.8in

\hskip-1.75in
\hbox to \paperwidth{\includegraphics[width=8.5in]{StatisticsLetterhead.pdf}}%

\setlength{\voffset}{0in}%
\setlength{\headheight}{12pt}%

\egroup

}
%\includegraphics[width=8.5in]{StatisticsLetterhead}}

%\def\letterhead{\begin




\def\TO#1{\begin{letter}{#1}}
\let\greeting=\opening
\def\signed{\closing{Sincerely,
%\vskip.5in
\includegraphics[width=2in]{signature.pdf}\\
David Pollard\\
Professor of Statistics\\% \qquad and Mathematics\\
Yale University}
}

%\endinput%%%23 Oct 2015
\makeatletter
%\renewenvironment{letter}[1]
\newenvironment{letter}[1]
  {%\newpage
    \if@twoside \ifodd\c@page
                \else\thispagestyle{empty}\null\newpage\fi
    \fi
    \c@page \@ne
    \c@footnote \z@
    \interlinepenalty=200 % smaller than the TeXbook value
    \@processto{\leavevmode\ignorespaces #1}}
  {\stopletter\@@par\pagebreak\@@par
    \if@filesw
      \begingroup
        \let\\=\relax
        \let\protect\@unexpandable@protect
        \immediate\write\@auxout{%
          \string\@mlabel{\returnaddress}{\toname\\\toaddress}}%
      \endgroup
    \fi}
\makeatother
%\voffset=-2in
\headsep=0pt
%\showthe\textwidth
\setlength\textwidth{5in}
\setlength\textheight{8.7in}
\setlength\topmargin{0pt}
