You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
vkoves
changed the title
Total climate pollution chart & projection to 0 by 2050
Add Homepage Total US Pollution Chart with Projection to 0 by 2050
Mar 25, 2022
As I expect the emissions data to lag behind the current year (current data ends 2018 and we are in 2022), how should the "missing data" be handled in the SimpleAreaChart. Do we want a gap? Do we project from the last year in which we have data? Something else?
@hkier the chart should show the projection based on the last year of data we have. It'll be on us to find data up to 2022 and handle that in a separate issue we already have open #10
The way the component is currently written, the historical data ends in 2018. 2019-2021 have no data. The projection starts at 2022 using the historical data from the last year of historical data as a starting point. It is not obvious from the area graph there are years with missing data.
The code is written in such a way, it does not matter when the historical data ends. It is also written so we can add "estimated data" for the missing data or just ignore the gap.
I assume even though we might be missing data, we do not want the graph to show a gap.
Using
Recharts
create a new Component chart that shows current US emissions and what we need to do to get to 0 by 2050:Example spreadsheet and chart: https://docs.google.com/spreadsheets/d/1QIWu0BSWCW2AgrJilhcsPA20jTdDjxqNJGoMx9c8-Iw/edit#gid=0
Steps
SimpleAreaChart
with 2 series (actual + projection) https://recharts.org/en-US/examples/SimpleAreaChartThe text was updated successfully, but these errors were encountered: