Hi and welcome.
Not sure of better way, but you could hold the last 4 values in context and at certain time of day read context and average.
e.g.
[{"id":"262a06c7.d1a87a","type":"inject","z":"c74669a0.6a34f8","name":"at set time","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":150,"y":880,"wires":[["65f10022.76a3c8"]]},{"id":"65f10022.76a3c8","type":"change","z":"c74669a0.6a34f8","name":"","rules":[{"t":"set","p":"payload","pt":"msg","to":"$average($flowContext(\"hold\"))","tot":"jsonata"}],"action":"","property":"","from":"","to":"","reg":false,"x":360,"y":880,"wires":[["7e06057b.d1b80c"]]},{"id":"7e06057b.d1b80c","type":"debug","z":"c74669a0.6a34f8","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":570,"y":840,"wires":[]},{"id":"7f3522a3.fa06ac","type":"inject","z":"c74669a0.6a34f8","name":"incoming readins","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"$ceil($random()*5)","payloadType":"jsonata","x":180,"y":800,"wires":[["c99a39e2.503808"]]},{"id":"c99a39e2.503808","type":"change","z":"c74669a0.6a34f8","name":"","rules":[{"t":"set","p":"hold","pt":"flow","to":"$append([payload],$flowContext(\"hold\"))[[0..3]]","tot":"jsonata"}],"action":"","property":"","from":"","to":"","reg":false,"x":290,"y":800,"wires":[[]]}]