Welcome to Tesla Motors Club
Discuss Tesla's Model S, Model 3, Model X, Model Y, Cybertruck, Roadster and More.
Register

Comparing Tesla and Utility Usage Data

This site may earn commission on affiliate links.
Some of the discussion regarding meters and the differences got me wondering how close the data from Tesla and my utility (PEPCO) actually were. Full discussion below, but it appears that Tesla consistently reports a lower net usage than PEPCO. The amount varies from almost 0 to a bit over half a kWh, but, on a daily basis, it is always positive. In fitting the data, it seems that there is a constant daily difference of about 0.24 kWh plus a difference of just under 1% of the net use for the day. The discrepancy is not huge, but it does come out to just over 10 kWh per month (about $1.50 based on PEPCO rates.)

I obtained the Tesla data using the local API to query the TEG. The TEG provides data on 4 meters - site, battery, load, and solar - and each provides an amount imported and exported (load exported is always 0, and solar imported is virtually 0 - ~0.003 kWh avg. daily.) I confirmed that Site Import - Site Export = Load Import - Solar Export + Solar Import - Battery Export + Battery Import. In other words, the Tesla data balances, so that there is no missing Energy in their data. As such, I used Site Import - Site Export to represent the "Tesla Usage".

For PEPCO, I pulled the Green Button data, which, in our area, includes hourly usage data. Because PEPCO's meters provide only a single net usage number, PEPCO does not provide separate generation and use numbers that I could compare to the Tesla data. To double-check the Green Button data, I compared it to the two bills we have received and confirmed that the numbers match, rounded to the nearest kWh (all billing is done in whole kWh amounts.)

The attached graph shows that the data matches very well. However, what is notable (though difficult to see) is that the PEPCO number always represents higher usage than Tesla.

For the second chart I used the regression tool in LibreOffice, which provides a best fit of 0.240 kWh + 0.00960 * Tesla net usage. I did also try fitting all of the other data sets to see if they had a better correlation but found nothing else came close (other than fitting to the PEPCO Net Usage, which provides, not surprisingly, virtually the same fit and correlation of 0.238 kWh + 0.00952 * PEPCO net usage.) The chart shows that, as
 

Attachments

  • NetEnergyUsage.png
    NetEnergyUsage.png
    66.1 KB · Views: 66
  • NetEnergyUsageTrend.png
    NetEnergyUsageTrend.png
    29.6 KB · Views: 39
  • Informative
Reactions: jjrandorin
Nice! Do you know if Tesla also has a remote API for usage and production data? Since I won't have any powerwalls with my solar roof, my understanding is I won't have a TEG (and consequently won't have a local API to the TEG). I'd still love to be able to pull and store usage and production data. I'm also not familiar with Tesla's app. I wonder how much historical data it allows you to access.
 
Nice! Do you know if Tesla also has a remote API for usage and production data? Since I won't have any powerwalls with my solar roof, my understanding is I won't have a TEG (and consequently won't have a local API to the TEG). I'd still love to be able to pull and store usage and production data. I'm also not familiar with Tesla's app. I wonder how much historical data it allows you to access.

There is an API - Tesla API seems to have documentation of it. Others would have more familiarity with its use and any limitations. The app seems (so far) to have all of my data still available for download. However, it has to be downloaded one day at a time to get the 5-minute level data (I assume it is the same for solar only - downloading over longer times only provides daily energy use.) I have also found that while the app data is good enough in general, for the most precise data, it is not the best source as it only provides the 5-minute data to the nearest 0.1 kW, potentially introduces some error by showing the instant power (in kW) numbers at the time instead of energy, and it also (though this may not be an issue for solar only) fudges the numbers a bit compared to the API to handle reporting the battery drain.
 
Yes, your solar roof should appear in the Tesla APIs. Mine does. And I think _all_ of the Tesla APIs are “work in progress.” Or, more accurately, they are not officially supported by Tesla for anything other than their apps. Any 3rd party use of them would be “at your own risk.” But I have found the energy APIs to be useful and stable for me since I started using them earlier this year.