% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/01_angle.R
\name{dms_to_deg}
\alias{dms_to_deg}
\title{Convert Degrees, Minutes, and Seconds (DMS) to Decimal Degrees}
\usage{
dms_to_deg(d, m, s, digit = 5)
}
\arguments{
\item{d}{Numeric or character. The degrees component. If a single character
string is provided (e.g., \code{"12\u00B034'56\""}), the degrees, minutes,
and seconds are parsed automatically, and \code{m} and \code{s} should be
omitted.}

\item{m}{Numeric. The minutes component. Must be less than 60. Optional when
\code{d} is a string.}

\item{s}{Numeric. The seconds component. Must be less than 60. Optional when
\code{d} is a string.}

\item{digit}{Integer. Number of decimal places to round the result to.
Default is \code{5}.}
}
\value{
Numeric. The angle in decimal degrees.
}
\description{
Converts an angle expressed in Degrees-Minutes-Seconds (DMS) format to
decimal degrees. Accepts either separate numeric arguments or a single
formatted string.
}
\examples{
dms_to_deg(d = 12, m = 34, s = 56)
dms_to_deg(d = "12\u00B034'56\"", digit = 3)
}
