I am trying to figure out how I can use the Mongodb JS SDK to modify the binning setting in my data. I am not able to find anything in the SDK documentation- basically my use case is- I want to show a Day of the Month bin when the user selects monthly in a drop down, and a Week bin when the user selects weekly and so on. Is this an option?
Skip to main content
2 years later
Have you found out the answer of it ? I want to do the same. How can I if you know ?
Unfortunately this is not supported yet, but the ability to dynamically change things like binning is planned for the future. For now, you’d need to create multiple charts with different binning settings, and swap in the correct one for the user’s context.
Tom
New & Unread Topics
Topic | Replies | Views | Activity |
---|---|---|---|
Comparing Two Columns in Mongo Charts (Using Table) | 1 | 770 | May 2024 |
Getting chart data using api | 2 | 514 | Jun 2024 |
Chart SDK - ‘preFilter’ property is not available for createChart() method in @mongodb-js/charts-embed-dom | 3 | 295 | Jul 2024 |
How can we access the data.metadata.age to determine when was the data last refreshed, from our embedding charts UI code | 0 | 145 | Aug 2024 |
Embedded Charts Tooltip customization | 0 | 32 | Nov 2024 |