time channel
TODO
- [x] filter: equal to the current time
- [x] filter: less than or equal to the current time
- [x] filter: less than the current time
- [x] filter: greater than or equal to the current time
- [x] filter: greater than the current time
- [x] filter: not equal to the current time
- [x] filter: near the current time? other arbitrary time predicates?
- [x] interpolate when the current time is between known values
- [ ] faceting
- [ ] declarative control over animation (delay, duration, iterations, etc.)
- [ ] imperative control over animation (play, pause, etc.)
- [ ] assigning the current time (plot.currentTime = 1956?)
Future work?
- (optionally) varying scales
- fast incremental re-rendering of marks
- animated transitions using the Web Animations API
- time legend that allows interactive control over the current time?
- facets: #1018
- transforms: draft (not working yet) in #1019
Notes on animation: https://observablehq.com/d/f51c8c5a84470d6f
Some demos of this work:
https://github.com/observablehq/plot/assets/230541/407048db-91e6-4643-b754-5140261aca6c
https://github.com/observablehq/plot/assets/230541/c536df41-de86-47a8-a290-58f9542baeb8
https://github.com/observablehq/plot/assets/230541/3715ec7d-8a41-42b9-a87e-fc7de817faf0
https://github.com/observablehq/plot/assets/230541/a4cc9ae7-dd13-4687-bbbc-6c11ea17b0f2
https://github.com/observablehq/plot/assets/230541/eb08cefb-b187-46c2-b91e-f61d0e8d66fe
https://github.com/observablehq/plot/assets/230541/b5c195d0-bd30-407e-8213-2973598e85f4