Skip to content

Add time series plot explorer for numeric and date columns - #849

Merged
cristian-tamblay merged 1 commit into
developfrom
feat/time-series-explorer
Sep 1, 2026
Merged

cristian-tamblay merged 1 commit into
developfrom
feat/time-series-explorer

Conversation

@Irozuku

@Irozuku Irozuku commented Aug 31, 2026

Copy link
Copy Markdown
Collaborator

Summary

Adds TimeSeriesPlotExplorer, so a target column can actually be looked at over time.

ScatterPlotExplorer was the nearest existing thing and does not work here for two independent reasons. Its allowed_types is [Float, Integer, Categorical], so it will not accept a Date column at all. And because a dashAI Date is stored as text, adding Date to that list would make Plotly treat the axis as unordered categories drawn in row order rather than chronological order. That is a wrong plot, not a limited one.


Type of Change

Check all that apply like this [x]:

  • Backend change
  • Frontend change
  • CI / Workflow change
  • Build / Packaging change
  • Bug fix
  • Documentation

Changes (by file)

  • DashAI/back/exploration/explorers/time_series_plot.py: new explorer. Reads the dates with the format the column already declares, sorts them, and passes real datetimes to Plotly, so the horizontal axis is a genuine time axis and gaps stay visible. allowed_types = [Date, Float, Integer], input_cardinality = {"min": 2}. validate_columns is tightened past the inherited check, which would accept two numbers and no date, or two dates and no series.
  • DashAI/back/initial_components.py: register the explorer.
  • tests/back/exploration/test_time_series_plot.py: new. 12 tests.

Testing (optional)

  • Create the plot inside the app with a time series dataset.

Notes (optional)

input_cardinality is a minimum rather than exactly two on purpose: one date plus several series on shared axes is the more useful version and costs nothing, since px.line takes a list of y columns.

Dates are read with the declared format rather than reguessed, so the plot can never disagree with the stored type. A column whose format is wrong raises instead of drawing a plausible but wrong picture.

@Irozuku Irozuku added the back Backend work label Aug 31, 2026
@cristian-tamblay
cristian-tamblay force-pushed the feat/time-series-explorer branch from c991be8 to 7c8128b Compare August 31, 2026 22:27
Base automatically changed from feat/time-series-window-converter to develop September 1, 2026 12:58
Draws numeric columns against a date column as lines over time. The dates are
read with the format the column already declares, sorted, and passed as real
datetimes, so the axis is a genuine time axis and gaps stay visible instead of
collapsing into evenly spaced categories.

The existing scatter explorer could not do this: it does not accept Date, and
since a Date is stored as text it would have plotted the axis as unordered
categories in row order.

validate_columns is tightened beyond the inherited type check, which would
accept two numbers and no date, or two dates and no series.
@cristian-tamblay
cristian-tamblay force-pushed the feat/time-series-explorer branch from 7c8128b to 0ba0569 Compare September 1, 2026 12:58
@cristian-tamblay
cristian-tamblay merged commit 07c459a into develop Sep 1, 2026
21 checks passed
@cristian-tamblay
cristian-tamblay deleted the feat/time-series-explorer branch September 1, 2026 14:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

back Backend work

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants