Homey Community Forum

[APP] Insight Trends

PLEASE NOTE THAT THERE IS A CONFLICT BETWEEN ATHOM AND THE DEVELOPER OF THIS APPLICATION AS ATHOM ACTIVELY DEMANDS IMPLEMENTATION OF FEATURES THEY WANT TO HAVE AND OTHERWISE WONT PUBLISH THE APP IN THEIR STORE. AS THIS SOFTWARE WAS DEVELOPED IN NO RELATION TO ATHOM AND AS THE DEVELOPER ISN’T A PAID CONTRACTOR OR IN A SIMILAR RELATION TO ATHOM THIS CANNOT BE ACCEPTED. THE DEVELOPEMENT AND THE SUPPORT OF THIS APPLICATION IS HERBY TERMINATED UNTIL FURTHER NOTICE.

Introduction

Homey features powerful insights that allow you to see all sensor measurements and it’s development in the past. Get one step further and not only see the insights put also act accordingly or even see a little bit into the future!

Coming soon!

The app provides a bunch of action- and condition flow cards where you select an insight (a device and a capability, i.e. temperature outside) and a scope to analyse (i.e. the last 15 minutes). The following results will then be calculated:

  • Trend: a value between -1 and 1 indicating if the sensors measurement is going up or down (and how fast/slow). for example a value of 0.75 means the trend is going up rapidly while -0.1 means a slight downwards trend
  • Min/max: the minimal/maximal value discovered within the scope
  • Average: the average of all values in the scope (arithmetic mean)
  • Median: if all values would get sorted and if you take the value in the middle this is the median
  • Standard deviation: indicator active/inactive the measured value or how ‘spreaded’ the data set is
  • Dataset size: how many measurements the scope has. This can be useful to determine how trustworthy the results above are. For example if you have a sensor that only reports every 30 minutes and your scope is one hour you will get some results but they are based on just two measurements so the trend is maybe not that accurate. Important: a bigger scope might not have a bigger dataset than a smaller one as the accuracy (and therefore the sample points) also get is reduced.

Example usage scenarios

  • If you have an humidity sensor and you want an alarm to go off if the humidity is too high. When you take a shower it might be that the alarm goes on because you have a very high humidity for a short amount of time which is okay. Before you trigger the alarm you now might check the average humidity over the past 4 hours and only trigger the alarm if also this value is high.
  • Long term analysis: you could analyse if for example the temperature is going up or down over a longer period of time and accordingly take measurements early (heating/cooling). Because you are considering a longer period of time this basically excludes short term events such as a rainy weekend during the summer.
  • You not only get the current measurements but you also get insights how it came to the current measurement. If you’re monitoring the temperature for example you would see from the trend if the temperature raised/dropped rather fast or slowly which can indicate different reasons, i.e. an open window versus a minor problem with your heating system.
  • Less complex flow scenarios: for some reason you might need to now if the temperature went bellow zero in the last night. Instead of having to listen to all events and store the lowest temperature and resetting this variable you might just use the insights to check this at any time for any scope.
  • Act early: instead of triggering an alarm when it is already too late you might analyse the trends and give a warning early. For example you might want to prevent mold by monitoring humidity and temperature. Depending of the current values and also it’s trends you then can detect this risk early!
  • Detect if some behaviour starts to change: for example if you have a vibration sensor on your washing machine you could see if something is wrong if the standard deviation increases over time.

14 Likes

reserved

reserved too

Love this idea,

Having the mode (modus) would be great too.
The mode is the value that appears most often in a set of data values

Good idea, do you have any example where that could be useful?

I am monitoring the water Temperature of my heater (Ingoing and outgoing)
I prefer to see the modus rather than the avarage or median
Example:
Measurements 70, 70, 70, 70, 60, 40, 40, 30, 30,
Median is 60
Avarage is 53.3
Modus is 70

1 Like

How expensive is an insights card in terms of CPU and memory use? I can see how useful it is, but I’m worried it will be a heavy operation that you might need to call periodically.

Good question! Actually it is suprisingly low, I’ll be able to get into more details soon (fetching log entries is around a few 100 ms in general and calculating things is even faster). Calculating a few trends per second should not be a problem but maybe you should not query it all the time for all your devices.

3 Likes

Please note that there is a conflict between athom and the developer of this application as athom actively demands implementation of features they want to have and otherwise wont publish the app in their store. as this software was developed in no relation to athom and as the developer isn’t a paid contractor or in a similar relation to athom this cannot be accepted. the developement and the support of this application is herby terminated until further notice. If you have questions, please ask Athom

3 Likes

Anyway the app is splendid! Thank You for your effort to make Homey more useful and effective. Your app has made my flows much more simple to configure.

Despite the conflict, I am happy with this app… Let’s see if this flow will work out for me when showering, purple line, three moments… When motion is detected > switch light on + kick off the attached flow…

Trends only works retrospectively. Do you not think you need to trigger flow on change of humidity?

Thanks @Morgan!

For now I created a flow: Based on movement, lights+log writing… Including starting of this flow… this flow should start and than trigger should come because of these spikes in humidity. The humidity is continuous changing… Up but also down… Any suggestions are welcome.

I also want that when there is no humidity change, still the lights switch on when motion is detected… that’s why I separated these flows…

I stumbled into a problem with the app. If have more than one scope calculated, in different flows, for a capacity like outdoor temperatur, the When-card “Trend calculated” do not recognize which scope it shall report for.
I have one scope for outdoor temperatur to calculate minimum temperatur the last 8 hours.and another scope for outdoor temperatur to calculate the average temperatur the last 7 days.
Either of these to flows fires the “Trend calculated” and I do not now which scope is used. :frowning:

Is there a way to set a variable to the calculated mean for example? So if I want to calculate the average temperature of the last 24 hours, can I write this number to a variable? I can trigger actions when a calculation had been done but can’t seem to find the result of the calculation…

This flow runs when a trend calculation is made. Then it updates a variable with minimum value rounded to 1 decimal. Then it is sent to my mobile.