\HeaderA{DMS-class}{Class "DMS" for degree, minute, decimal second values}{DMS.Rdash.class}
\aliasA{as.double.DMS}{DMS-class}{as.double.DMS}
\aliasA{as.numeric.DMS}{DMS-class}{as.numeric.DMS}
\aliasA{coerce,DMS-method}{DMS-class}{coerce,DMS.Rdash.method}
\aliasA{print.DMS}{DMS-class}{print.DMS}
\aliasA{show,DMS-method}{DMS-class}{show,DMS.Rdash.method}
\keyword{classes}{DMS-class}
\keyword{spatial}{DMS-class}
\begin{Description}\relax
The class provides a container for coordinates stored as degree, minute, decimal second values.
\end{Description}
\begin{Section}{Objects from the Class}
Objects can be created by calls of the form \code{new("DMS", ...)}, converted from decimal degrees using \code{dd2dms()}, or converted from character strings using \code{char2dms()}.
\end{Section}
\begin{Section}{Slots}
\describe{
\item[\code{WS}:] Object of class \code{"logical"} TRUE if input value negative
\item[\code{deg}:] Object of class \code{"numeric"} degrees
\item[\code{min}:] Object of class \code{"numeric"} minutes
\item[\code{sec}:] Object of class \code{"numeric"} decimal seconds
}
\end{Section}
\begin{Section}{Methods}
\describe{
\item[coerce] \code{signature(from = "DMS", to = "numeric")}: convert to decimal degrees 
\item[show] \code{signature(object = "DMS")}: print data values 
}
\end{Section}
\begin{Author}\relax
Roger Bivand \email{Roger.Bivand@nhh.no}
\end{Author}
\begin{SeeAlso}\relax
\code{\LinkA{char2dms}{char2dms}}, \code{\LinkA{dd2dms}{dd2dms}}
\end{SeeAlso}
\begin{Examples}
\begin{ExampleCode}
data(state)
dd2dms(state.center$x)
dd2dms(state.center$y, NS=TRUE)
as.numeric(dd2dms(state.center$y))
as(dd2dms(state.center$y, NS=TRUE), "numeric")
as.numeric.DMS(dd2dms(state.center$y))
state.center$y
\end{ExampleCode}
\end{Examples}

