Black Lives Matter. Please consider donating to Black Girls Code today.

Python Figure Reference: layout.geo

  • geo
    Code: fig.update_geos(...)
    Type: dict containing one or more of the keys listed below.
    • domain
      Code: fig.update_geos(domain=dict(...))
      Type: dict containing one or more of the keys listed below.
      • x
        Code: fig.update_geos(domain_x=<VALUE>)
        Type: list
        Default: [0, 1]

        Sets the horizontal domain of this geo subplot (in plot fraction). Note that geo subplots are constrained by domain. In general, when `projection.scale` is set to 1. a map will fit either its x or y domain, but not both.

      • y
        Code: fig.update_geos(domain_y=<VALUE>)
        Type: list
        Default: [0, 1]

        Sets the vertical domain of this geo subplot (in plot fraction). Note that geo subplots are constrained by domain. In general, when `projection.scale` is set to 1. a map will fit either its x or y domain, but not both.

      • row
        Code: fig.update_geos(domain_row=<VALUE>)
        Type: integer greater than or equal to 0
        Default: 0

        If there is a layout grid, use the domain for this row in the grid for this geo subplot . Note that geo subplots are constrained by domain. In general, when `projection.scale` is set to 1. a map will fit either its x or y domain, but not both.

      • column
        Code: fig.update_geos(domain_column=<VALUE>)
        Type: integer greater than or equal to 0
        Default: 0

        If there is a layout grid, use the domain for this column in the grid for this geo subplot . Note that geo subplots are constrained by domain. In general, when `projection.scale` is set to 1. a map will fit either its x or y domain, but not both.

    • fitbounds
      Code: fig.update_geos(fitbounds=<VALUE>)
      Type: enumerated , one of ( False | "locations" | "geojson" )

      Determines if this subplot's view settings are auto-computed to fit trace data. On scoped maps, setting `fitbounds` leads to `center.lon` and `center.lat` getting auto-filled. On maps with a non-clipped projection, setting `fitbounds` leads to `center.lon`, `center.lat`, and `projection.rotation.lon` getting auto-filled. On maps with a clipped projection, setting `fitbounds` leads to `center.lon`, `center.lat`, `projection.rotation.lon`, `projection.rotation.lat`, `lonaxis.range` and `lonaxis.range` getting auto-filled. If "locations", only the trace's visible locations are considered in the `fitbounds` computations. If "geojson", the entire trace input `geojson` (if provided) is considered in the `fitbounds` computations, Defaults to "False".

    • resolution
      Code: fig.update_geos(resolution=<VALUE>)
      Type: enumerated , one of ( "110" | "50" )
      Default: "110"

      Sets the resolution of the base layers. The values have units of km/mm e.g. 110 corresponds to a scale ratio of 1:110,000,000.

    • scope
      Code: fig.update_geos(scope=<VALUE>)
      Type: enumerated , one of ( "world" | "usa" | "europe" | "asia" | "africa" | "north america" | "south america" )
      Default: "world"

      Set the scope of the map.

    • projection
      Code: fig.update_geos(projection=dict(...))
      Type: dict containing one or more of the keys listed below.
      • type
        Code: fig.update_geos(projection_type=<VALUE>)
        Type: enumerated , one of ( "equirectangular" | "mercator" | "orthographic" | "natural earth" | "kavrayskiy7" | "miller" | "robinson" | "eckert4" | "azimuthal equal area" | "azimuthal equidistant" | "conic equal area" | "conic conformal" | "conic equidistant" | "gnomonic" | "stereographic" | "mollweide" | "hammer" | "transverse mercator" | "albers usa" | "winkel tripel" | "aitoff" | "sinusoidal" )

        Sets the projection type.

      • rotation
        Code: fig.update_geos(projection_rotation=dict(...))
        Type: dict containing one or more of the keys listed below.
        • lon
          Code: fig.update_geos(projection_rotation_lon=<VALUE>)
          Type: number

          Rotates the map along parallels (in degrees East). Defaults to the center of the `lonaxis.range` values.

        • lat
          Code: fig.update_geos(projection_rotation_lat=<VALUE>)
          Type: number

          Rotates the map along meridians (in degrees North).

        • roll
          Code: fig.update_geos(projection_rotation_roll=<VALUE>)
          Type: number

          Roll the map (in degrees) For example, a roll of "180" makes the map appear upside down.

      • parallels
        Code: fig.update_geos(projection_parallels=<VALUE>)
        Type: list

        For conic projection types only. Sets the parallels (tangent, secant) where the cone intersects the sphere.

      • scale
        Code: fig.update_geos(projection_scale=<VALUE>)
        Type: number greater than or equal to 0
        Default: 1

        Zooms in or out on the map view. A scale of "1" corresponds to the largest zoom level that fits the map's lon and lat ranges.

    • center
      Code: fig.update_geos(center=dict(...))
      Type: dict containing one or more of the keys listed below.
      • lon
        Code: fig.update_geos(center_lon=<VALUE>)
        Type: number

        Sets the longitude of the map's center. By default, the map's longitude center lies at the middle of the longitude range for scoped projection and above `projection.rotation.lon` otherwise.

      • lat
        Code: fig.update_geos(center_lat=<VALUE>)
        Type: number

        Sets the latitude of the map's center. For all projection types, the map's latitude center lies at the middle of the latitude range by default.

    • visible
      Code: fig.update_geos(visible=<VALUE>)
      Type: boolean
      Default: True

      Sets the default visibility of the base layers.

    • showcoastlines
      Code: fig.update_geos(showcoastlines=<VALUE>)
      Type: boolean

      Sets whether or not the coastlines are drawn.

    • coastlinecolor
      Code: fig.update_geos(coastlinecolor=<VALUE>)
      Type: color
      Default: "#444"

      Sets the coastline color.

    • coastlinewidth
      Code: fig.update_geos(coastlinewidth=<VALUE>)
      Type: number greater than or equal to 0
      Default: 1

      Sets the coastline stroke width (in px).

    • showland
      Code: fig.update_geos(showland=<VALUE>)
      Type: boolean

      Sets whether or not land masses are filled in color.

    • landcolor
      Code: fig.update_geos(landcolor=<VALUE>)
      Type: color
      Default: "#F0DC82"

      Sets the land mass color.

    • showocean
      Code: fig.update_geos(showocean=<VALUE>)
      Type: boolean

      Sets whether or not oceans are filled in color.

    • oceancolor
      Code: fig.update_geos(oceancolor=<VALUE>)
      Type: color
      Default: "#3399FF"

      Sets the ocean color

    • showlakes
      Code: fig.update_geos(showlakes=<VALUE>)
      Type: boolean

      Sets whether or not lakes are drawn.

    • lakecolor
      Code: fig.update_geos(lakecolor=<VALUE>)
      Type: color
      Default: "#3399FF"

      Sets the color of the lakes.

    • showrivers
      Code: fig.update_geos(showrivers=<VALUE>)
      Type: boolean

      Sets whether or not rivers are drawn.

    • rivercolor
      Code: fig.update_geos(rivercolor=<VALUE>)
      Type: color
      Default: "#3399FF"

      Sets color of the rivers.

    • riverwidth
      Code: fig.update_geos(riverwidth=<VALUE>)
      Type: number greater than or equal to 0
      Default: 1

      Sets the stroke width (in px) of the rivers.

    • showcountries
      Code: fig.update_geos(showcountries=<VALUE>)
      Type: boolean

      Sets whether or not country boundaries are drawn.

    • countrycolor
      Code: fig.update_geos(countrycolor=<VALUE>)
      Type: color
      Default: "#444"

      Sets line color of the country boundaries.

    • countrywidth
      Code: fig.update_geos(countrywidth=<VALUE>)
      Type: number greater than or equal to 0
      Default: 1

      Sets line width (in px) of the country boundaries.

    • showsubunits
      Code: fig.update_geos(showsubunits=<VALUE>)
      Type: boolean

      Sets whether or not boundaries of subunits within countries (e.g. states, provinces) are drawn.

    • subunitcolor
      Code: fig.update_geos(subunitcolor=<VALUE>)
      Type: color
      Default: "#444"

      Sets the color of the subunits boundaries.

    • subunitwidth
      Code: fig.update_geos(subunitwidth=<VALUE>)
      Type: number greater than or equal to 0
      Default: 1

      Sets the stroke width (in px) of the subunits boundaries.

    • showframe
      Code: fig.update_geos(showframe=<VALUE>)
      Type: boolean

      Sets whether or not a frame is drawn around the map.

    • framecolor
      Code: fig.update_geos(framecolor=<VALUE>)
      Type: color
      Default: "#444"

      Sets the color the frame.

    • framewidth
      Code: fig.update_geos(framewidth=<VALUE>)
      Type: number greater than or equal to 0
      Default: 1

      Sets the stroke width (in px) of the frame.

    • bgcolor
      Code: fig.update_geos(bgcolor=<VALUE>)
      Type: color
      Default: "#fff"

      Set the background color of the map

    • lonaxis
      Code: fig.update_geos(lonaxis=dict(...))
      Type: dict containing one or more of the keys listed below.
      • range
        Code: fig.update_geos(lonaxis_range=<VALUE>)
        Type: list

        Sets the range of this axis (in degrees), sets the map's clipped coordinates.

      • showgrid
        Code: fig.update_geos(lonaxis_showgrid=<VALUE>)
        Type: boolean

        Sets whether or not graticule are shown on the map.

      • tick0
        Code: fig.update_geos(lonaxis_tick0=<VALUE>)
        Type: number
        Default: 0

        Sets the graticule's starting tick longitude/latitude.

      • dtick
        Code: fig.update_geos(lonaxis_dtick=<VALUE>)
        Type: number

        Sets the graticule's longitude/latitude tick step.

      • gridcolor
        Code: fig.update_geos(lonaxis_gridcolor=<VALUE>)
        Type: color
        Default: "#eee"

        Sets the graticule's stroke color.

      • gridwidth
        Code: fig.update_geos(lonaxis_gridwidth=<VALUE>)
        Type: number greater than or equal to 0
        Default: 1

        Sets the graticule's stroke width (in px).

    • lataxis
      Code: fig.update_geos(lataxis=dict(...))
      Type: dict containing one or more of the keys listed below.
      • range
        Code: fig.update_geos(lataxis_range=<VALUE>)
        Type: list

        Sets the range of this axis (in degrees), sets the map's clipped coordinates.

      • showgrid
        Code: fig.update_geos(lataxis_showgrid=<VALUE>)
        Type: boolean

        Sets whether or not graticule are shown on the map.

      • tick0
        Code: fig.update_geos(lataxis_tick0=<VALUE>)
        Type: number
        Default: 0

        Sets the graticule's starting tick longitude/latitude.

      • dtick
        Code: fig.update_geos(lataxis_dtick=<VALUE>)
        Type: number

        Sets the graticule's longitude/latitude tick step.

      • gridcolor
        Code: fig.update_geos(lataxis_gridcolor=<VALUE>)
        Type: color
        Default: "#eee"

        Sets the graticule's stroke color.

      • gridwidth
        Code: fig.update_geos(lataxis_gridwidth=<VALUE>)
        Type: number greater than or equal to 0
        Default: 1

        Sets the graticule's stroke width (in px).

    • uirevision
      Code: fig.update_geos(uirevision=<VALUE>)
      Type: number or categorical coordinate string

      Controls persistence of user-driven changes in the view (projection and center). Defaults to `layout.uirevision`.