I may have misunderstood what you are asking. The Join node does join on timestamp. It does so on a group by group basis. Since you are grouping by fingerprint, it will group points that have the same fingerprint together.
Could you share some of the specific data points you wish to combine in order to compute the EMA? That will help me understand exactly what you are trying to do. On Friday, November 4, 2016 at 2:45:57 PM UTC-6, ni...@gratafy.com wrote: > > As far as I understand it the join node will join based on timestamps. > Since in this case, I'm looking to join based on the value of a tag, I'm > not sure the join node has what I'm looking for. > "As each data point is received from a parent node it is paired with the > next data points from the other parent nodes with a matching timestam" > > > On Thursday, November 3, 2016 at 5:54:41 PM UTC-7, ni...@gratafy.com > wrote: >> >> I'm wondering if it would actually be possible to calculate exponential >> moving average using a tick script. >> >> for instance where exponential moving average for number of pings in a >> time period would be calculated as follows: >> >> Multiplier: (2 / (Time periods + 1) ) = (2 / (10 + 1) ) = 0.1818 (18.18%) >> >> EMA: ((# of pings for some period - last plotted EMA point) x multiplier) + >> last plotted EMA point >> >> >> To do this I need to do something like >> >> >> >> var currentPings = batch >> |query('select sum(count) from telegraf.seven_days.pos_heartbeat') >> .every(1m) >> .period(1m) >> .groupBy(time(1m), 'fingerprint') >> .align() >> .offset(1m) >> >> var pingsWithMultiplier = currentPings >> |eval(lambda: 2.0 / (10.0 + 1.0), lambda: "sum" + 0.0) >> .as('multiplier', 'total') >> >> var lastEma = batch >> |query('select last(avg) from >> telegraf.seven_days.pos_heartbeat_ema') >> .groupBy('fingerprint') >> >> ---- at this point I need a way to combine lastEma and >> pingsWIthMultiplier nodes on tags where 'fingerprint' == 'fingerprint' --- >> >> Based on the documentation I've read, there's not currently a good way to >> do this. Am I missing something? Thanks in advance for any guidance! >> >> >> -- Remember to include the version number! --- You received this message because you are subscribed to the Google Groups "InfluxData" group. To unsubscribe from this group and stop receiving emails from it, send an email to influxdb+unsubscr...@googlegroups.com. To post to this group, send email to influxdb@googlegroups.com. Visit this group at https://groups.google.com/group/influxdb. To view this discussion on the web visit https://groups.google.com/d/msgid/influxdb/7bd3b7bc-4b8c-4c02-ae3e-534c1c6ea08f%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.