Before I get to the subject would someone please tell me how to get the hand replayer to go through the hands from the beginning of the tournament (or session) to the end instead of from the end back to the beginning?
I have created 4 new columns and two new stats to track the percentage of times a player raises allin preflop when they have the opportunity and the average equity when it is known.
I limit hands to those with 5+ players and to the player having > 10 BB, this is easily changed.
Just checking on bullies.
The test "tourney_hand_player_statistics.id_blinds = tourney_blinds.id_blinds" seems unnecessary. Does PT4 do these joins automatically?
The test "tourney_hand_player_statistics.enum_face_allin SIMILAR TO '(N|p)' " seems redundant, I include it in the hope of speeding up the query. I'm new to PT4 so I could definitely be wrong on this point. it may not speed up the query and its apparent redundancy could be a coincidence.
If any mistakes are noticed please reply, otherwise your welcome to the code. The code has been tested and I'm pretty sure it is correct. It is my first attempt though so please check my work before using.
COLUMNS
cnt_p_allin_raiser_5plusP_10plusBB
sum( if[tourney_hand_player_statistics.id_blinds = tourney_blinds.id_blinds AND
tourney_hand_player_statistics.enum_allin = 'P' AND
tourney_hand_player_statistics.enum_face_allin SIMILAR TO '(N|p)' AND
tourney_hand_player_statistics.cnt_players>4 AND
(tourney_hand_player_statistics.amt_before /
tourney_blinds.amt_BB)>10 AND
tourney_hand_player_statistics.amt_bet_p > 0 AND
tourney_hand_player_statistics.amt_before =
( tourney_hand_player_statistics.amt_blind +
tourney_hand_player_statistics.amt_ante +
tourney_hand_player_statistics.amt_bet_p) AND
tourney_hand_player_statistics.amt_bet_p = tourney_hand_player_statistics.amt_p_raise_made, 1, 0] )
opp_p_allin_raiser_5plusP_10plusBB
sum( if[tourney_hand_player_statistics.id_blinds = tourney_blinds.id_blinds AND
tourney_hand_player_statistics.enum_face_allin <> 'P' AND
tourney_hand_player_statistics.cnt_players > 4 AND
( tourney_hand_player_statistics.amt_before /
tourney_blinds.amt_BB) > 10, 1, 0] )
val_p_allin_raiser_5plusP_10plusBB
sum( if[tourney_hand_player_statistics.id_blinds = tourney_blinds.id_blinds AND
tourney_hand_player_statistics.enum_allin = 'P' AND
tourney_hand_player_statistics.enum_face_allin SIMILAR TO '(N|p)' AND
tourney_hand_player_statistics.cnt_players>4 AND
(tourney_hand_player_statistics.amt_before /
tourney_blinds.amt_BB)>10 AND
tourney_hand_player_statistics.amt_bet_p > 0 AND
tourney_hand_player_statistics.amt_before =
( tourney_hand_player_statistics.amt_blind +
tourney_hand_player_statistics.amt_ante +
tourney_hand_player_statistics.amt_bet_p) AND
tourney_hand_player_statistics.amt_bet_p = tourney_hand_player_statistics.amt_p_raise_made,
tourney_hand_player_statistics.val_equity, 0] )
cnt_val_p_allin_raiser_5plusP_10plusBB
sum( if[tourney_hand_player_statistics.id_blinds = tourney_blinds.id_blinds AND
tourney_hand_player_statistics.enum_allin = 'P' AND
tourney_hand_player_statistics.enum_face_allin SIMILAR TO '(N|p)' AND
tourney_hand_player_statistics.cnt_players>4 AND
(tourney_hand_player_statistics.amt_before /
tourney_blinds.amt_BB)>10 AND
tourney_hand_player_statistics.amt_bet_p > 0 AND
tourney_hand_player_statistics.amt_before =
( tourney_hand_player_statistics.amt_blind +
tourney_hand_player_statistics.amt_ante +
tourney_hand_player_statistics.amt_bet_p) AND
tourney_hand_player_statistics.amt_bet_p = tourney_hand_player_statistics.amt_p_raise_made AND
tourney_hand_player_statistics.val_equity > 0, 1, 0] )
STATS
ALL-in Preflop 5+P 10+BB
(cnt_p_allin_raiser_5plusp_10plusBB / opp_p_allin_raiser_5plusp_10plusBB) * 100
Avg Equity All-in Preflop 5+P 10+BB
(val_p_allin_raiser_5plusp_10plusBB / cnt_val_p_allin_raiser_5plusp_10plusBB) * 100