Torque

Forums

Forums

AVG Formula questio...
 
Notifications
Clear all

AVG Formula question

6 Posts
2 Users
0 Reactions
1,189 Views
(@spiderman)
Posts: 98
Estimable Member
Topic starter
 

Hi All,

English is not my main language so please bear with me
🙂
in the wiki it says:

AVG(bucketSize:value)

Point average. This averages incoming values from a bucket of s set size. The bucket can be configured to average a set amount of values, so AVG(10,value) would average the last 10 values

if I use AVG(10:value)does that mean it waits for the first 10 values, averages them and output the value the WAITS for the NEXT 10,averages them and outputs the value ?

the above is what I am trying to do for a KM/L formula to stop the output from changing very fast (3-5 times a second) but it doesn't seem to do it as above 🙁

thank you!

 
Posted : 11/11/2016 1:14 pm
(@capp777)
Posts: 2999
Famed Member
 

I suggest looking at the EWMAF function as a
possible solution with a weight closer to zero,
e.g., 0.1.

https://torque-bhp.com/wiki/Equations

 
Posted : 11/11/2016 3:37 pm
(@spiderman)
Posts: 98
Estimable Member
Topic starter
 

Thanks a lot for your help,

Can you please explain what that function exactly do please ?

 
Posted : 11/11/2016 4:10 pm
(@capp777)
Posts: 2999
Famed Member
 

It uses an exponentially weighted moving
average to filter the value. The weight determines
how much it's smoothed (damped) or not.

Graphing the results at both extremes should give
you an idea how well it works. (I used Val{Tilt(z)} for
beta testing with graphs one overtop the other to
see the effect).

It provides a filter for smoothing noisey signals like
you seem to be describing.

Edited.

 
Posted : 11/11/2016 5:50 pm
(@spiderman)
Posts: 98
Estimable Member
Topic starter
 

Ok, will experement with it and post here

Thank you very much!

 
Posted : 11/11/2016 7:10 pm
(@spiderman)
Posts: 98
Estimable Member
Topic starter
 

Tried it this morning, unfortunately it did not effect the very fast display changing. With or without it i can see no difference at all. I used 0.1 as weight

Can you think of any thing els to slow down the display please?

Thanks

 
Posted : 13/11/2016 9:56 am
Share:

  Follow me on twitter