Graphics

 View Only
  • 1.  Comparing number values to drive a highlight condition

    Posted 10-01-2018 18:13
    I know this can be done, because I have seen it, but I've never built this logic myself, so before I start going down the rabbit hole, I thought I would reach out to see if I could get some guidance.

    Simple setup, L3rd for a poll, the answer with the highest number should be highlighted along with the answer choice. So, if it were a 4 question (A, B, C, D) poll, and B got the highest percentage, I'd want that number and answer text for B to automatically highlight.

    Thanks in advance,
    Willie


  • 2.  RE: Comparing number values to drive a highlight condition

    Posted 10-01-2018 18:18
    An example I created for a shot clock in an older thread: https://discussions.rossvideo.com/filedata/fetch?id=11101
    #XPression


  • 3.  RE: Comparing number values to drive a highlight condition

    Posted 10-01-2018 18:20
    Errr. actually that probably won't work...as any of your 4 answers could be the highest, and my example has linear values.
    #XPression


  • 4.  RE: Comparing number values to drive a highlight condition

    Posted 10-01-2018 18:49
    I did a thing like this with Andrew Sampson in Baltimore, wherein we had to create a highlight condition for the higher score in a graphic showing games in progress, I kind of remember it, but it was a few months ago and I've slept alot since then...
    #XPression


  • 5.  RE: Comparing number values to drive a highlight condition

    Posted 10-02-2018 22:07
    hey will please check my attached logic.
    The connection to the light is just arbitrary. The use of the trunc block was because the selector blocks were treating everything like a boolean and I wanted to use integer values. I could have just as easily attached value blocks instead but heyho it works.
    #XPression


  • 6.  RE: Comparing number values to drive a highlight condition

    Posted 10-03-2018 17:23

    Hey Red, thanks. I will check it out. I tried yesterday using a string compare, but for some reason it was only taking the first number into account - so for 68 it was only looking at 6 (even though the pop up that shows output values saw the whole 68, and it was acting as if 68 were smaller than 7... perplexing and maybe a bug (?), but I ultimately got it to work with <= blocks. I am always looking for cleaner solutions though so I'll for sure see what you cooked up.

    I attached snaps of what I did for a 2-question percentage based numerical answer, and another which was multiple choice A-D. Just to compare notes as it were:


    #XPression


  • 7.  RE: Comparing number values to drive a highlight condition

    Posted 10-03-2018 17:30
    I don't know why I initially thought what you had posted was a XPP... so looking instead at the screen shot you sent, I see that we more or less had the same idea, though I had never even looked at the max value or trunc blocks before.
    #XPression


  • 8.  RE: Comparing number values to drive a highlight condition

    Posted 10-03-2018 20:33
    The Trunc blocks removes all numbers after a decimal without rounding so can be useful but I just wanted the selected to see an integer and it was an easy way to do it.

    Looks like you had a similar idea but I recommend using the max block method, as you can see it's very easy to scale it up for more answers if needed.
    #XPression