Adding Math that can divide sum by time range

I am wanting to display solar power generated by adding the total watt hrs together then dividing by the time

ie) if I am on a 24 hr range I can “sum” all the watt hrs and then divide by 60 this will give my how many kw has been produced

my main issue is using “singlestat” I have to use (value stat average) and using “gauge” I can use (value stat Total) but no way to add a maths formula to divide it by time to convert my watt-hrs into kw

and why do I not have any metric options like the documentation
v6.1.4 commit: fef1733