<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">\HeaderA{download.SP500PriceReturns}{download S \&amp; P Prices and calculate S \&amp; P returns}{download.SP500PriceReturns}
\keyword{ts}{download.SP500PriceReturns}
\keyword{multivariate}{download.SP500PriceReturns}
\keyword{distribution}{download.SP500PriceReturns}
\keyword{models}{download.SP500PriceReturns}
\begin{Description}\relax
This function downloads daily/monthly S \&amp; P 500 \emph{prices} using \code{\LinkA{get.hist.quote}{get.hist.quote}} for "\^gspc" and calculate S \&amp; P \emph{returns} using \code{\LinkA{CalculateReturns}{CalculateReturns}}
\end{Description}
\begin{Usage}
\begin{verbatim}
download.SP500PriceReturns(start = "1998-01-01", end = NULL, compression=c("m","d"), method=c("compound","simple"))
\end{verbatim}
\end{Usage}
\begin{Arguments}
\begin{ldescription}
\item[\code{start}] start date in YYYY-mm-dd format, default "1998-01-01"
\item[\code{end}] end date in YYYY-mm-dd format
\item[\code{compression}] "m" for monthly returns and "d" for daily returns, default monthly, as passthru to \code{\LinkA{get.hist.quote}{get.hist.quote}}
\item[\code{method}] "simple" or "compound" as a passthru to \code{\LinkA{CalculateReturns}{CalculateReturns}}, default compound
\end{ldescription}
\end{Arguments}
\begin{Value}
matrix of simple or compound returns on the S \&amp; P 500 at the daily/monthly scale specified
\end{Value}
\begin{Author}\relax
Peter Carl
\end{Author}
\begin{SeeAlso}\relax
\code{\LinkA{CalculateReturns}{CalculateReturns}} \\
\code{\LinkA{download.RiskFree}{download.RiskFree}} \\
\code{\LinkA{get.hist.quote}{get.hist.quote}}
\end{SeeAlso}
\begin{Examples}
\begin{ExampleCode}
sp500 = download.SP500PriceReturns(start = "1996-12-31", end = "2007-01-01")
class(sp500)
head(sp500)
\end{ExampleCode}
\end{Examples}

</pre></body></html>