pvlib.location.Location#

class pvlib.location.Location(latitude, longitude, tz='UTC', altitude=0, name=None)[source]#

Location objects are convenient containers for latitude, longitude, timezone, and altitude data associated with a particular geographic location. You can also assign a name to a location object.

Location objects have two timezone attributes:

  • tz is a IANA timezone string.

  • pytz is a pytz timezone object.

Location objects support the print method.

Parameters
  • latitude (float.) – Positive is north of the equator. Use decimal degrees notation.

  • longitude (float.) – Positive is east of the prime meridian. Use decimal degrees notation.

  • tz (str, int, float, or pytz.timezone, default 'UTC'.) – See http://en.wikipedia.org/wiki/List_of_tz_database_time_zones for a list of valid time zones. pytz.timezone objects will be converted to strings. ints and floats must be in hours from UTC.

  • altitude (float, default 0.) – Altitude from sea level in meters.

  • name (string, optional) – Sets the name attribute of the Location object.

Methods

__init__(latitude, longitude[, tz, ...])

from_epw(metadata[, data])

Create a Location object based on a metadata dictionary from epw data readers.

from_tmy(tmy_metadata[, tmy_data])

Create an object based on a metadata dictionary from tmy2 or tmy3 data readers.

get_airmass([times, solar_position, model])

Calculate the relative and absolute airmass.

get_clearsky(times[, model, solar_position, ...])

Calculate the clear sky estimates of GHI, DNI, and/or DHI at this location.

get_solarposition(times[, pressure, temperature])

Uses the pvlib.solarposition.get_solarposition() function to calculate the solar zenith, azimuth, etc.

get_sun_rise_set_transit(times[, method])

Calculate sunrise, sunset and transit times.

Examples using pvlib.location.Location#

Simulating PV system DC output using the ADR module efficiency model

Simulating PV system DC output using the ADR module efficiency model

Fixed-Tilt Simulation with pvfactors

Fixed-Tilt Simulation with pvfactors

Bifacial Modeling - procedural

Bifacial Modeling - procedural

Bifacial Modeling - modelchain

Bifacial Modeling - modelchain

Mixed Orientation

Mixed Orientation

Reverse transposition using one year of hourly data

Reverse transposition using one year of hourly data

GHI to POA Transposition

GHI to POA Transposition

Seasonal Tilt

Seasonal Tilt

Modeling with interval averages

Modeling with interval averages

Modeling Transposition Gain

Modeling Transposition Gain

Simple irradiance adjustment for horizon shading

Simple irradiance adjustment for horizon shading

Dual-Axis Tracking

Dual-Axis Tracking

Discontinuous Tracking

Discontinuous Tracking