Energy Usage Graph showing anomylous readings

I’m using Reimann Sum helper to give a cumulative energy reading from a sensor that updates each second. It’s been quite accurate but every now and again gives a completely spurious reading. For example this between 6-7am:
image
The inputs to the Reimann Sum has one tiny spike of one reading (one second) at 433W on the ‘export’ reading, and zero for the rest of the hour, but even with trapezoidal Reimann sum, I can’t see how that accounts for a 1.7kWh export reading?

This has happened a few times now. I’ve seen some advice to change the Reimann sum integration to ‘left’ rather than ‘trapezoidal’ but that would require deleting and recreating the helpers, unless someone can point me a way to edit them? And I’m not convinced it’ll help; the maths just doesn’t add up

Thanks for your help!

Here’s the spike:

I tend to refrain from posting on forums like this as I always end up anwering my own question.
So, after some thought, here’s what I suspect is happening…
The blips that seem small on the graph are quite possibly bigger blips than are shown there due to the way it’s graphed. Perhaps my emonlib-based energy meter gave a ridiculously high reading due to some grid power fluctuation, and the trapezoidal Reimann sum calculation used the top of that to decide the power used in that minute.
The conclusion is, I need a bit of a filter on my meter! Also, left-based Reimann sum would probably fix this

It was useful information for me…