How to use the metar.Datatypes.position function in metar

To help you get started, we’ve selected a few metar examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github python-metar / python-metar / metar / Station.py View on Github external
def __init__(
        self, id, city=None, state=None, country=None, latitude=None, longitude=None
    ):
        self.id = id
        self.city = city
        self.state = state
        self.country = country
        self.position = position(latitude, longitude)
        if self.state:
            self.name = "%s, %s" % (self.city, self.state)
        else:
            self.name = self.city