tidbyt / community

A publishing platform for apps developed by the Tidbyt community 🚀
Apache License 2.0
379 stars 643 forks source link

CArenewable clean energy percentage at/above 100% #2338

Closed burritojustice closed 4 months ago

burritojustice commented 5 months ago

The clean energy percentage in the CA Renewable app is coming in at or above 100%. While this is a desirable energy policy goal, this doesn't match up with the CAISO dashboard.

image image

I believe this is because batteries are being added to total power in line 32, when they shouldn't be included while they are charging / negative -- adding them in while the are negative is throwing off the renewable total. I believe the same applies to negative import values (aka exports…) However, both values would need to be added to the total when they are positive.

https://github.com/tidbyt/community/blob/d588d98e5b1926b3dd9aa91cb304d4dc515440c2/apps/carenewables/ca_renewables.star#L32

Showing batteries might be interesting given they are largely powered by solar during the day -- perhaps below the x-axis when they are charging.

Thanks for a fun app!

burritojustice commented 5 months ago

Also, the chart breaks when values are above 100% image image

stale[bot] commented 4 months ago

We're automatically closing this issue because it hasn't had any activity in 30 days. If that seems like a mistake, please feel free to re-open. Thanks!