functime-org / functime

Time-series machine learning at scale. Built with Polars for embarrassingly parallel feature extraction and forecasts on panel data.
https://docs.functime.ai
Apache License 2.0
971 stars 52 forks source link

feat(plotting): add sampling param #158

Closed baggiponte closed 4 months ago

baggiponte commented 6 months ago

I've been meaning to do this for a while now. Plotting functions now have a num_series param (and seed) to sample some series (by default, 10). In this way, users don't have to do the filtering themselves.

Don't know if this implementation is optimal. We are still collecting all entities.

I also would like to implement a "rank_by" to plot images in order. Adding another parameter is the fastest way but I am not in love with it: too much complexity.

I am leaving this here, as food for thought: I am tempted by the OOP approach:

y = functime.PanelDataFrame.from_polars(...) # basically a LazyFrame with some type checks and stores the "state" AKA entity, time and value cols

y.rank(by=..., how="best").plot(n_series=10)
vercel[bot] commented 6 months ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
functime-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 5, 2024 10:51pm