Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions After Effects Expression Random Number Counter 0-100 But Numbers Change Too Quickly (Math.round)

  • After Effects Expression Random Number Counter 0-100 But Numbers Change Too Quickly (Math.round)

    Posted by Jesse Beavers on August 1, 2019 at 4:54 pm

    Hi,

    I am attempting to make a dynamic bar graph with fluctuating numbers to convey that the results of a poll are still in the midst of being calculated. I haven’t even gotten so far as how to address how the bars will animate, but for the numbers I am currently using the expression Math.round(random(0,100)). The expression works, but the numbers move very rapidly and it would be nice to have more control over how fast the numbers fluctuate.

    Is there a way to slow down the Math.round(random(0,100)) expression? Also, if someone has a recommendation on how to animate the bars moving up and down to match the numbers, that would be even better.

    Thanks!

    Math.round(random(0,100))

    Jesse Beavers replied 6 years, 9 months ago 2 Members · 2 Replies
  • 2 Replies
  • Dan Ebberts

    August 1, 2019 at 7:00 pm

    You could do something like this to have it change, for example, 5 times per second:

    posterizeTime(5);
    Math.round(random(0,100))

    Dan

  • Jesse Beavers

    August 1, 2019 at 7:05 pm

    That did the trick!

    You da man, Dan! Thank you!

    posterizeTime(5);
    Math.round(random(0,100))

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy