Quantcast
Channel: Desktop topics
Viewing all articles
Browse latest Browse all 216047

Moving Average in Seconds

$
0
0

PowerBI / DAX are well equipped for period groupings that involve days, months, quarters and years.  But, despite the description of time intelligence, there does not appear to be much (if any) functionality for time itself.  Our dataset is standard IoT log variety:

DATATIMESTAMP,DEVICEID,Vp (other values omitted) in one second intervals.  As is so often the case with these things, there is a lot of noise in the readings.  Therefore, we need to smooth out the values using averaging.

 

Given a set of data that looks like this:

DataTimestampDeviceNameVp
5/22/2016 0:00:00NSB-00353.1021
5/22/2016 0:00:01NSB-00353.0524
5/22/2016 0:00:02NSB-00353.127
5/22/2016 0:00:03NSB-00353.1021
5/22/2016 0:00:04NSB-00353.0773
5/22/2016 0:00:05NSB-00353.0524
5/22/2016 0:00:06NSB-00352.9779
5/22/2016 0:00:07NSB-00353.1021
5/22/2016 0:00:08NSB-00353.0773

 

How can we calculate the average of now + 4 previous readings, then calculate the delta of change between this "now" average and the average from 3 seconds past?  Any help would be greatly appreciated!

 

Thanks.


Viewing all articles
Browse latest Browse all 216047

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>