Parsers and formatters of angles in degrees, minutes and seconds or
radians.
Functions to parse and format bearing, compass, lat- and longitudes in
various forms of degrees, minutes and seconds with or without degrees,
minute and second symbols plus a compass point suffix, including parsing
of decimal
and sexagecimal
degrees.
|
bearingDMS(bearing,
form=' d ' ,
prec=None,
sep='',
**s_D_M_S)
Convert bearing to a string (without compass point suffix). |
|
|
|
clipDegrees(deg,
limit)
Clip a lat- or longitude to the given range. |
|
|
|
clipRadians(rad,
limit)
Clip a lat- or longitude to the given range. |
|
|
|
compassDMS(bearing,
form=' d ' ,
prec=None,
sep='',
**s_D_M_S)
Convert bearing to a string suffixed with compass point. |
|
|
|
compassPoint(bearing,
prec=3)
Convert bearing to a compass point. |
|
|
|
degDMS(deg,
prec=6,
s_D=' ° ' ,
s_M=' \xe2\x80\xb2 ' ,
s_S=' ″ ' ,
neg='-',
pos='')
Convert degrees to a string in degrees, minutes or seconds. |
|
|
|
latDMS(deg,
form=' dms ' ,
prec=2,
sep='',
**s_D_M_S)
Convert latitude to a string, optionally suffixed with N or S. |
|
|
|
latlonDMS(lls,
form=' dms ' ,
prec=None,
sep=None,
**s_D_M_S)
Convert one or more LatLon instances to strings. |
|
|
|
latlonDMS_(*lls,
**form_prec_sep_s_D_M_S)
Convert one or more LatLon instances to strings. |
|
|
|
lonDMS(deg,
form=' dms ' ,
prec=2,
sep='',
**s_D_M_S)
Convert longitude to a string, optionally suffixed with E or W. |
|
|
|
normDMS(strDMS,
norm=None,
**s_D_M_S)
Normalize all degrees, minutes and seconds (DMS) symbols in a string
to the default symbols S_DEG, S_MIN, S_SEC. |
|
|
|
parseDDDMMSS(strDDDMMSS,
suffix=' NSEW ' ,
sep='',
clip=0,
sexagecimal=False)
Parse a lat- or longitude represention forms as [D]DDMMSS in degrees. |
|
|
|
parseDMS(strDMS,
suffix=' NSEW ' ,
sep='',
clip=0,
**s_D_M_S)
Parse a lat- or longitude representation in degrees . |
|
|
|
parseDMS2(strLat,
strLon,
sep='',
clipLat=90,
clipLon=180,
**s_D_M_S)
Parse a lat- and a longitude representions "lat,
lon" in degrees . |
|
|
|
parse3llh(strllh,
height=0,
sep=',',
clipLat=90,
clipLon=180,
**s_D_M_S)
Parse a string "lat lon [h]" representing
lat-, longitude in degrees and optional height in
meter . |
|
|
|
parseRad(strRad,
suffix=' NSEW ' ,
clip=0)
Parse a string representing angle in radians . |
|
|
|
precision(form,
prec=None)
Set the default precison for a given F_ form. |
|
|
|
toDMS(deg,
form=' dms ' ,
prec=2,
sep='',
ddd=2,
neg='-',
pos='+',
**s_D_M_S)
Convert signed degrees to string, without suffix. |
|
|
|
__all__ = _ALL_LAZY.dms
|
|
S_DEG = ' ° '
Degrees symbol, default "°"
|
|
S_MIN = ' \xe2\x80\xb2 '
Minutes symbol, default "′" aka PRIME
|
|
S_SEC = ' ″ '
Seconds symbol, default "″" aka
DOUBLE_PRIME
|
|
S_RAD = ''
Radians symbol, default "" aka
pygeodesy.NN
|
|
S_SEP = ''
Separator between deg°|min′|sec″|suffix , default
"" aka pygeodesy.NN
|
|
F_D = ' d '
Format degrees as unsigned "deg°" with symbol, plus compass
point suffix N, S, E or W
(str ).
|
|
F_D60 = ' d60 '
Format degrees as unsigned "[D]DD.MMSS"
sexagecimal without symbols, plus suffix
(str ).
|
|
F_D60_ = '-d60'
Format degrees as signed "-/[D]DD.MMSS"
sexagecimal without symbols, without
suffix (str ).
|
|
F_D60__ = '+d60'
Format degrees as signed "-/+[D]DD.MMSS"
sexagecimal without symbols, without
suffix (str ).
|
|
F_DEG = ' deg '
Format degrees as unsigned "[D]DD" without symbol,
plus suffix (str ).
|
|
F_DEG_ = '-deg'
Format degrees as signed "-/[D]DD" without symbol,
without suffix (str ).
|
|
F_DEG__ = '+deg'
Format degrees as signed "-/+[D]DD" without symbol,
without suffix (str ).
|
|
F_DM = ' dm '
Format degrees as unsigned "deg°min′" with symbols, plus
suffix (str ).
|
|
F_DMS = ' dms '
Format degrees as unsigned "deg°min′sec″" with symbols,
plus suffix (str ).
|
|
F_DMS_ = '-dms'
Format degrees as signed "-/deg°min′sec″" with symbols,
without suffix (str ).
|
|
F_DMS__ = '+dms'
Format degrees as signed "-/+deg°min′sec″" with symbols,
without suffix (str ).
|
|
F_DM_ = '-dm'
Format degrees as signed "-/deg°min′" with symbols,
without suffix (str ).
|
|
F_DM__ = '+dm'
Format degrees as signed "-/+deg°min′" with symbols,
without suffix (str ).
|
|
F_D_ = '-d'
Format degrees as signed "-/deg°" with symbol,
without suffix (str ).
|
|
F_D__ = '+d'
Format degrees as signed "-/+deg°" with symbol,
without suffix (str ).
|
|
F_MIN = ' min '
Format degrees as unsigned "[D]DDMM" without
symbols, plus suffix (str ).
|
|
F_MIN_ = '-min'
Format degrees as signed "-/[D]DDMM" without
symbols, without suffix (str ).
|
|
F_MIN__ = '+min'
Format degrees as signed "-/+[D]DDMM" without
symbols, without suffix (str ).
|
|
F_RAD = ' rad '
Convert degrees to radians and format as unsigned "RR" with
symbol, plus suffix (str ).
|
|
F_RAD_ = '-rad'
Convert degrees to radians and format as signed "-/RR"
without symbol, without suffix (str ).
|
|
F_RAD__ = '+rad'
Convert degrees to radians and format as signed "-/+RR"
without symbol, without suffix (str ).
|
|
F_SEC = ' sec '
Format degrees as unsigned "[D]DDMMSS" without
symbols, plus suffix (str ).
|
|
F_SEC_ = '-sec'
Format degrees as signed "-/[D]DDMMSS" without
symbols, without suffix (str ).
|
|
F_SEC__ = '+sec'
Format degrees as signed "-/+[D]DDMMSS" without
symbols, without suffix (str ).
|
|
F__E = ' e '
Format degrees as unsigned "%E" without symbols,
plus suffix (str ).
|
|
F__E_ = '-e'
Format degrees as signed "-/%E" without symbols,
without suffix (str ).
|
|
F__E__ = '+e'
Format degrees as signed "-/+%E" without symbols,
without suffix (str ).
|
|
F__F = ' f '
Format degrees as unsigned "%F" without symbols,
plus suffix (str ).
|
|
F__F_ = '-f'
Format degrees as signed "-/%F" without symbols,
without suffix (str ).
|
|
F__F__ = '+f'
Format degrees as signed "-/+%F" without symbols,
without suffix (str ).
|
|
F__G = ' g '
Format degrees as unsigned "%G" without symbols,
plus suffix (str ).
|
|
F__G_ = '-g'
Format degrees as signed "-/%G" without symbols,
without suffix (str ).
|
|
F__G__ = '+g'
Format degrees as signed "-/+%G" without symbols,
without suffix (str ).
|