Skip to main content
{% point_layer
    data="store_locations"
    lat="latitude"
    lng="longitude"
    point_title="store_name"
/%}

Examples

Colored by Value

{% point_layer
    data="store_sales"
    lat="latitude"
    lng="longitude"
    point_title="store_name"
    color_value="sum(sales)"
    color_palette=["#feedde", "#fdd0a2", "#fdae6b", "#fd8d3c", "#e6550d", "#a63603"]
    color_value_fmt="usd"
/%}

Sized by Value

{% point_layer
    data="store_locations"
    lat="latitude"
    lng="longitude"
    point_title="store_name"
    size_value="sum(customers)"
/%}

Color and Size by Different Values

{% point_layer
    data="store_metrics"
    lat="latitude"
    lng="longitude"
    color_value="sum(sales)"
    size_value="sum(customers)"
    color_palette=["#feedde", "#fdd0a2", "#fdae6b", "#fd8d3c", "#e6550d", "#a63603"]
/%}

Categorical Coloring

{% point_layer
    data="locations"
    lat="latitude"
    lng="longitude"
    point_title="name"
    color_value="category"
    color_palette=["#236aa4", "#45a1bf", "#a5cdee", "#8dacbf", "#85c7c6"]
/%}

Attributes

data
String
required
Name of the table to query
filters
Array
default:"[]"
Array of filter IDs to apply
lat
String
required
Column name for latitude values
lng
String
required
Column name for longitude values
color_value
String
Column or expression for coloring points. Numeric values create a gradient scale, categorical values (strings) assign discrete colors from the palette. Examples: “sum(sales)” (numeric gradient), “category” (categorical colors)
size_value
String
Column or expression for sizing points (e.g., “sum(customers)”). If not provided, all points will be the same size
point_title
String
Column name to use as the point title in tooltips (e.g., “city_name”). If not provided, lat/lng will be shown
point_subtitle
String
Column name to use as the point subtitle in tooltips (e.g., “region”). Displays as a second line with muted text
shape
String
default:"circle"
Shape of the point markerAllowed values:
  • circle
  • pin
  • square
  • triangle
  • star
  • diamond
color
String
Single color for all points (hex, rgb/rgba, or CSS color name)
color_palette
Array of colors for coloring. For numeric color_value: creates gradient. For categorical color_value: assigns discrete colors to categories (cycles if more categories than colors)
size
Number
default:"6"
Base size of points in pixels
size_scale
Number
default:"1"
Scale multiplier for value-based sizing. Higher values create larger size differences
tooltip
Boolean
default:"true"
Show tooltips on hover
tooltip_fields
Array of SQL expressions for additional fields to show in tooltip (e.g., [“category”, “emissions”])
color_value_fmt
String
default:"num"
Format for color values in tooltip
size_value_fmt
String
default:"num"
Format for size values in tooltip
zoom_threshold
Zoom range [min, max] where this layer is visible (e.g., [0, 8] shows layer from zoom 0 to 8)
legend
Boolean
default:"true"
Show legend for this layer
legend_label
String
Custom label for the legend (defaults to table name)
where
String
Custom SQL WHERE condition to apply to the query. For date filters, use date_range instead.
having
String
Custom SQL HAVING condition to apply to the query after GROUP BY
limit
Number
Maximum number of rows to return from the query
order
String
Column name(s) with optional direction (e.g. “column_name”, “column_name desc”)
qualify
String
Custom SQL QUALIFY condition to filter windowed results

Allowed Parents