PT EN
Back to site

DATTA BI — Cross-filter

Answering "what if I look only at this category?" used to require rebuilding the dashboard with another filter. With cross-filter, one click is enough: when you click a category in one visual, every other visual on the same dashboard filters instantly by that value — the whole analysis follows your focus, and a second click undoes it all.

How it works

  • One click on a bar, slice, point or marker propagates the filter to the whole dashboard.
  • Clicking again on the same element removes the filter — it is a toggle.
  • On the clicked visual: the selected element keeps its full color; the others dim (opacity 0.25). On a pie, the active slice also pops out, expanded by 6 px.
  • On the other visuals: all of them re-render already filtered, with the clicked value applied on top of the dashboard's saved filters.
  • To clear everything at once: the Limpar filtro (clear filter) button in the dashboard's top bar.

Visuals that emit cross-filter

  • Bars, horizontal bars and columns (bar, bar-horizontal, column)
  • Line and area (line, area)
  • Pie and donut (pie, donut)
  • Scatter and bubble (scatter, bubble)
  • Heatmap and treemap (heatmap, treemap)
  • Maps (map, map-google) — click a marker
  • Graph (graph) — click a node

They do not emit, by design: KPI and gauge, which have no clickable category, and table, which already brings its own column filter.

Cross-filter × drill-down

AspectCross-filterDrill-down
TriggerSingle clickDouble click
ScopeEvery visual on the dashboardOnly the clicked visual
Changes granularityNoYes — it goes down the axis hierarchy
What is re-renderedThe whole dashboardOnly the clicked visual
State keptOne global dashboard filter (field + value, or none)One detail level per visual

The two are independent: you can keep a cross-filter active and, at the same time, deep-dive a specific visual with drill-down.

Hands-on example — investigating a spike in cases

  1. On a dashboard with "Casos por UF" (bars), "Evolução mensal" (line) and "Distribuição por classe" (pie), click the SP bar.
  2. The line and the pie re-render showing only São Paulo — the March spike stands out on the line.
  3. Click the slice of the class with the largest share: the dashboard now shows only that class in SP.
  4. Click the same elements again to undo the filters, or use Limpar filtro to return to the overall view in one go.

How the filter is applied under the hood

  • The cross-filter state is unique per dashboard: one field + value pair, or no active filter.
  • Each visual type receives the active filter and returns the filter its click produced. That round trip is what lets you toggle it on and off from the same element.
  • The dimming and the "clickable" cursor only appear on visuals that actually emit cross-filter — one that does not emit never suggests that it does.
  • On the server, the clicked value arrives as an override and is merged with the filters already saved on the dashboard. When the clicked field does not match any persisted filter, the platform creates an equivalent text filter on the fly, so the value is applied all the same. The platform exposes endpoints to re-render the dashboard (cross-filter) and to render a single visual with drill — see the API reference.

Limitations

  • Visuals based on a handwritten DATTAX script only receive the filter if the script references it by name (@<nomeDoFiltro>). Visuals built through the column channels — dataset + field bindings — receive the filter automatically.
  • Heatmap and sankey emit the filter only through the X axis / flow source.
  • Each cross-filter re-renders the whole dashboard. The platform cache amortizes repeats of the same filter, but on very large dashboards prefer hierarchies with drill-down to explore details.