Displaying the daily consumption of a socket outlet

Hello dear Community,

I would like to create a graph that shows me the daily power consumption of my socket. The socket provides a value of “total consumption in kWh”.
So what I want to do is this:
Calculate max(total consumption) - min(total consumption) for today.

Is this possible? Thank you in advance!