Automatic colors statistics

Discuss how to create custom stats, reports and HUD profiles and share your creations.

Moderators: WhiteRider, kraada, Flag_Hippo, morny, Moderators

Re: Automatic colors statistics

Postby rubencash » Thu Aug 04, 2016 5:42 pm

Hello again.

I've been trying several days testing based on trial and error but I cannot find the correct expression.

You says:
if( a AND b, 1, 0)

That expression is easy, but I have problems with the use of "AND" and "OR" in longer chains because it affects the anterior and posterior expression. For example, I want that displayed 1 if any of them conditions between parentheses is certain although the others are false, but is mixed them conditions:

if( a AND b, 1, 0) OR if( c AND d, 1, 0) OR if ( e AND f, 1, 0), 0), 0)

But 'OR' does not work with the "Nested IFs" so this expression is not valid:

Code: Select all
if( (cnt_p_3bet_opp >10.00 AND cnt_p_3bet / cnt_p_3bet_opp) * 100 <=8.00 OR if( cnt_p_ccall_opp >10.00 AND cnt_p_ccall / cnt_p_ccall_opp) * 100 <=6.60 OR if( cnt_f_cbet_def_opp >10.00 AND cnt_f_cbet_def_action_fold / cnt_f_cbet_def_opp) * 100 >=46.42, 1, 0), 0), 0)



I also tried this:

Code: Select all
if( (cnt_p_3bet_opp >10.00 AND cnt_p_3bet / cnt_p_3bet_opp * 100 <=8.35) OR (cnt_p_ccall_opp >10.00 AND cnt_p_ccall / cnt_p_ccall_opp * 100 <=6.60) OR (cnt_f_cbet_def_opp >10.00 AND cnt_f_cbet_def_action_fold / cnt_f_cbet_def_opp * 100 >=46.42), 1, 0))



And this:

Code: Select all
if( (cnt_p_3bet_opp >10.00 AND cnt_p_ccall_opp >10.00 AND cnt_f_cbet_def_opp >10.00 AND (cnt_p_3bet / cnt_p_3bet_opp) * 100 <=8.35 AND (cnt_p_ccall / cnt_p_ccall_opp) * 100 <=6.60 AND (cnt_f_cbet_def_action_fold / cnt_f_cbet_def_opp) * 100 >=46.42, 1, 0 ))




The problem is that "AND" and "OR" not listed conditions as I want, which are minimal opportunities with its corresponding statistics. They just do also missing one of the 3 conditions (excluding opportunities) is true the number value to display "1".

Thank you very much beforehand, is driving me crazy this confusion.
rubencash
 
Posts: 152
Joined: Thu Aug 22, 2013 3:23 pm

Re: Automatic colors statistics

Postby kraada » Fri Aug 05, 2016 7:37 am

Please look at my example earlier - you will see that AND and OR both work in nested conditions. If you are uncertain about the priority, I recommend using parentheses to make things clear between the two.

The following is valid:

if (A OR B, 1, 0)

So is:

if( A and (B OR C), 1, 0)

The following is invalid:

if( A and if(B or C, 1, 0))

You cannot and an if() conditional with AND or OR. if() has three parts: if(A, B, C). All of A, B and C need to be valid statements that resolve - you cannot replace A with "A and" as that does not resolve to true or false. You can replace B or C with an if() statement as long as it follows the preceding rule. So when you want to put an if() within an if() most of the time you want to do it in B or C -- B is what happens when A is false and C is what happens when A is true. You just can't end A with "and" or "or".

Whenever you are doing a lot of testing you want to keep it in A though. As an example rewrite, this is valid:

if( (a AND b) or (c and d) or (e and f), 1, 0)
kraada
Moderator
 
Posts: 54435
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Automatic colors statistics

Postby rubencash » Sun Aug 07, 2016 9:18 am

Thanks a lot !!!!!!!!!
rubencash
 
Posts: 152
Joined: Thu Aug 22, 2013 3:23 pm

Re: Automatic colors statistics

Postby rubencash » Mon Aug 08, 2016 5:42 pm

Hello from new :P

Be can do so if the second or third condition are false displayed 7 and 9 respectively?


Code: Select all
if( (cnt_p_3bet / cnt_p_3bet_opp) * 100 <=13.35, if( (cnt_p_ccall / cnt_p_ccall_opp) * 100 <=10.60, if( (cnt_f_cbet_def_action_fold / cnt_f_cbet_def_opp) * 100 >=36.42, 4, 5), 7), 9)
rubencash
 
Posts: 152
Joined: Thu Aug 22, 2013 3:23 pm

Re: Automatic colors statistics

Postby kraada » Mon Aug 08, 2016 6:04 pm

If the first is true and second is false, it's 7. If the first is false, it's 9. If the first is false nothing else gets tested.
kraada
Moderator
 
Posts: 54435
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Automatic colors statistics

Postby rubencash » Tue Aug 09, 2016 12:36 pm

Thank you again kraada. Your explanation I solved the problem but I have that review your tutorials because not term of understand.

Can help me with another expression?

Code: Select all
if( (cnt_f_cbet_def_opp >= 10 AND (cnt_f_cbet_def_action_fold / cnt_f_cbet_def_opp) * 100 >= 40, format('X'), format_number, 0, false, false) )


Statistics is valid but throws me error, mean what I want to do.
rubencash
 
Posts: 152
Joined: Thu Aug 22, 2013 3:23 pm

Re: Automatic colors statistics

Postby kraada » Tue Aug 09, 2016 1:30 pm

format_number is a function. It works like this:
format_number(value, decimals, commas, color) where value is the value expression, decimals is the number of decimals to display, commas is true if you want commas at numbers larger than 999, and color is true if you want the value colored green for positive and red for negative.

So I believe what you want is this:

if( (cnt_f_cbet_def_opp >= 10 AND (cnt_f_cbet_def_action_fold / cnt_f_cbet_def_opp) * 100 >= 40, format('X'), format_number((cnt_f_cbet_def_action_fold / cnt_f_cbet_def_opp) * 100, 0, false, false) )

but depending on what you want to actually display when the fold to cbet value is less than 40, you may want something else there instead.
kraada
Moderator
 
Posts: 54435
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Automatic colors statistics

Postby rubencash » Tue Aug 09, 2016 3:15 pm

You always know what I want :P !

So already I satisfied, but the truth is that I would like to if the "fold to cbet" is less than 40 does not display nothing or to display the word 'NOT'.

I tried something like this but did not work, this is fun, but sometimes it takes crazy xD

Code: Select all
if( (cnt_f_cbet_def_opp >= 10 AND (cnt_f_cbet_def_action_fold / cnt_f_cbet_def_opp) * 100 >= 40, format('YES'), format_number((cnt_f_cbet_def_action_fold / cnt_f_cbet_def_opp) * 100 OR (cnt_f_cbet_def_opp < 10 OR (cnt_f_cbet_def_action_fold / cnt_f_cbet_def_opp) * 100 < 40, format('NOT'), format_number((cnt_f_cbet_def_action_fold / cnt_f_cbet_def_opp) * 100, 0, true, true )))))
rubencash
 
Posts: 152
Joined: Thu Aug 22, 2013 3:23 pm

Re: Automatic colors statistics

Postby kraada » Tue Aug 09, 2016 4:22 pm

Then you don't want numbers you want:

if( cnt_f_cbet_def_opp >= 10 AND (cnt_f_cbet_def_action_fold / cnt_f_cbet_def_opp) * 100 >= 40, format('YES'), format('NOT'))

If the antecedent is true it displays "YES" if not it displays "NOT".
kraada
Moderator
 
Posts: 54435
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Automatic colors statistics

Postby rubencash » Wed Aug 10, 2016 1:47 pm

Perfect!

I'm doing questions of fish and appreciate your patience.

I'm now trying something different, that conditions will only appear on the HUD when the opponent is in SB and I in BB, but before any action occurred in the table:

Code: Select all
if( i_am_bb_opponent_is_sb  AND (cnt_p_3bet_steal / cnt_p_3bet_steal_opp) * 100 <=8.35 AND (cnt_p_call_steal / cnt_p_call_steal_opp) * 100 <=6.60 AND (cnt_f_cbet_def_action_fold / cnt_f_cbet_def_opp) * 100 >=48.42, 5,

if( i_am_bb_opponent_is_sb AND (cnt_p_3bet_steal / cnt_p_3bet_steal_opp)) * 100 <=8.35 AND (cnt_p_call_steal / cnt_p_call_steal_opp) * 100 <=6.60, 3,

if( i_am_bb_opponent_is_sb  AND (cnt_p_3bet_steal / cnt_p_3bet_steal_opp)) * 100 <=8.35, 1, 4 )))


The "i_am_bb_opponent_is_sb" column:

Code: Select all
sum(if[tourney_hand_player_statistics.position =0 AND tourney_hand_summary.str_actors_p LIKE '9%' , 1, 0])


But "actors_p_ LIKE' 9% ' believe that not said what I need." I have to learn how to use the strings of rivals (and much more).

How would the expression in the column/statistics for what I need and where can I find information to build it?

Infinite thanks!
rubencash
 
Posts: 152
Joined: Thu Aug 22, 2013 3:23 pm

PreviousNext

Return to Custom Stats, Reports and HUD Profiles

Who is online

Users browsing this forum: No registered users and 12 guests

cron
highfalutin