% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/map.R
\name{oceProject}
\alias{oceProject}
\title{Wrapper to sf::sf_project()}
\usage{
oceProject(xy, proj, inv = FALSE, debug = getOption("oceDebug"))
}
\arguments{
\item{xy}{two-column numeric matrix specifying locations.  If \code{inv}
is False, then \code{xy[,1]} will hold longitude and \code{xy[,2]} will hold
latitude, but if \code{inv} is True, then the columns will be easting
and northing values (in metres).}

\item{proj}{a character value specifying the desired map
projection.  See the \code{projection} parameter of \code{\link[=mapPlot]{mapPlot()}} for
details, including a historical note dated 2023-04-11 about the
now-deprecated \code{sp} package.}

\item{inv}{logical value, False by default, indicating whether an
inverse projection is requested.}

\item{debug}{an integer specifying whether debugging information is
to be printed during the processing. This is a general parameter that
is used by many \code{oce} functions. Generally, setting \code{debug=0}
turns off the printing, while higher values suggest that more information
be printed. If one function calls another, it usually reduces the value of
\code{debug} first, so that a user can often obtain deeper debugging
by specifying higher \code{debug} values.}
}
\value{
\code{oceProject} returns a two-column matrix, with first column
holding either \code{longitude} or \code{x}, and second column holding either
\code{latitude} or \code{y}.
}
\description{
This function is used to isolate other oce functions from
changes to the map-projection functions that are done in the \CRANpkg{sf}
package.  (Until 2020 December, the \code{rgdal} package was used,
after a year of tests ensuring that the results of the two packages were
the same.)
}
\seealso{
Other functions related to maps: 
\code{\link{formatPosition}()},
\code{\link{lonlat2map}()},
\code{\link{lonlat2utm}()},
\code{\link{map2lonlat}()},
\code{\link{mapArrows}()},
\code{\link{mapAxis}()},
\code{\link{mapContour}()},
\code{\link{mapCoordinateSystem}()},
\code{\link{mapDirectionField}()},
\code{\link{mapGrid}()},
\code{\link{mapImage}()},
\code{\link{mapLines}()},
\code{\link{mapLocator}()},
\code{\link{mapLongitudeLatitudeXY}()},
\code{\link{mapPlot}()},
\code{\link{mapPoints}()},
\code{\link{mapPolygon}()},
\code{\link{mapScalebar}()},
\code{\link{mapText}()},
\code{\link{mapTissot}()},
\code{\link{oceCRS}()},
\code{\link{shiftLongitude}()},
\code{\link{usrLonLat}()},
\code{\link{utm2lonlat}()}
}
\author{
Dan Kelley
}
\concept{functions related to maps}
