Request for/help creating HU stats

Forum for users that want to write their own custom queries against the PT database either via the Structured Query Language (SQL) or using the PT3 custom stats/reports interface.

Moderator: Moderators

Request for/help creating HU stats

Postby madskills » Sat Dec 20, 2008 5:22 pm

Big Blind Bets Turn after C/Ring Flop
Big Blind Bets Turn after PFR checks back flop

Would these be difficult to create?
Any help greatly appreciated
Thanks!
madskills
 
Posts: 28
Joined: Mon May 19, 2008 7:42 pm

Re: Request for/help creating HU stats

Postby WhiteRider » Sat Dec 20, 2008 7:18 pm

Have a read of the Custom Statistics and Reports FAQ.

The first one would be pretty easy.
The big blind's position is always 8: holdem_hand_player_statistics.position
Bets the turn: holdem_hand_player_statistics.flg_t_bet
Check/raise the flop: you could either do..
( holdem_hand_player_statistics.flg_f_check AND holdem_hand_player_statistics.cnt_f_raise )
..or..
substring(lookup_actions_f.action from 1 for 2)='XR'
Actually, I just noticed there is a specific check/raise field I forgot about: holdem_hand_player_statistics.flg_f_check_raise
This doesn't take into account anyone else's actions, including number of opponents or whether the SB is active.

The second one is a bit trickier, since I guess you'll want to know that the PF raiser is not the SB?
Ignoring that, you will probably want this field in addition to the above:
NOT holdem_hand_player_statistics.flg_f_face_raise
WhiteRider
Moderator
 
Posts: 54025
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK

Re: Request for/help creating HU stats

Postby madskills » Sun Dec 21, 2008 10:34 am

Thanks!!!

Ok i'll work on the second one, hows this for the first?
It should work regardless of how many players are in the hand (I think)

C/R Flop and Bet Turn
(cnt_CR_flop_bet_turn / cnt_CR_flop_see_turn) * 100

cnt_CR_flop_bet_turn
sum(if[holdem_hand_player_statistics.flg_f_check_raise AND NOT
holdem_hand_player_statistics.flg_f_face_raise AND
holdem_hand_player_statistics.flg_t_bet, 1, 0])

cnt_CR_flop_see_turn
sum(if[holdem_hand_player_statistics.flg_f_check_raise AND NOT
holdem_hand_player_statistics.flg_f_face_raise AND
holdem_hand_player_statistics.flg_t_saw, 1, 0])
madskills
 
Posts: 28
Joined: Mon May 19, 2008 7:42 pm

Re: Request for/help creating HU stats

Postby madskills » Sun Dec 21, 2008 10:48 am

IDK about this one, trying to get what % of the time a guy fires turn after calling a raise pre and having the flop checked around.

Player is OOP
Player faces a raise preflop
Player does not 3bet preflop
Player checks the flop
Player does not face a flop bet
Player bets the turn

Steal Lead Turn OOP
(cnt_chkchk_flop_bet_turn / cnt_chkchk_flop) * 100

cnt_
sum(if[holdem_hand_player_detail.val_p_raise_aggressor_pos < holdem_hand_player_statistics.position AND
holdem_hand_player_statistics.flg_p_face_raise AND
holdem_hand_player_statistics.flg_p_3bet = FALSE AND
holdem_hand_player_statistics.flg_f_check AND NOT
holdem_hand_player_statistics.flg_f_face_bet AND
holdem_hand_player_statistics.flg_t_bet, 1, 0])

cnt_chkchk_flop
sum(if[holdem_hand_player_detail.val_p_raise_aggressor_pos < holdem_hand_player_statistics.position AND
holdem_hand_player_statistics.flg_p_face_raise AND
holdem_hand_player_statistics.flg_p_3bet = FALSE AND
holdem_hand_player_statistics.flg_f_check AND NOT
holdem_hand_player_statistics.flg_f_face_bet, 1, 0])
Last edited by madskills on Sun Dec 21, 2008 11:07 am, edited 1 time in total.
madskills
 
Posts: 28
Joined: Mon May 19, 2008 7:42 pm

Re: Request for/help creating HU stats

Postby madskills » Sun Dec 21, 2008 11:03 am

Here's one for delay cbets: (again these may be horrifically wrong, I've never done this before...)
I only play HU but Im pretty sure this should work regardless of how many people see the flop and whether player is in or out of position.

Player raises pre
Player's raise is the first raise
Player does not get 3bet
Player has an opportunity to Cbet (eliminates opp donks)
Player checks
Player doesn't face a bet on the flop
Player bets the turn

Delay CBet
(cnt_delay_cbet_turn / cnt_delay_cbet_turn_opp) * 100

cnt_delay_cbet_turn
sum(if[holdem_hand_player_statistics.flg_p_raise AND
holdem_hand_player_statistics.flg_p_first_raise AND
(holdem_hand_player_statistics.flg_p_3bet_def_opp = FALSE) AND
(holdem_hand_player_statistics.flg_f_cbet_opp = TRUE) AND
holdem_hand_player_statistics.flg_f_check AND NOT
holdem_hand_player_statistics.flg_f_face_bet AND
holdem_hand_player_statistics.flg_t_bet, 1, 0])

cnt_delay_cbet_turn_opp
sum(if[holdem_hand_player_statistics.flg_p_raise AND
holdem_hand_player_statistics.flg_p_first_raise AND
(holdem_hand_player_statistics.flg_p_3bet_def_opp = FALSE) AND
(holdem_hand_player_statistics.flg_f_cbet_opp = TRUE) AND
holdem_hand_player_statistics.flg_f_check AND NOT
holdem_hand_player_statistics.flg_f_face_bet, 1, 0])
madskills
 
Posts: 28
Joined: Mon May 19, 2008 7:42 pm

Re: Request for/help creating HU stats

Postby madskills » Sun Dec 21, 2008 11:13 am

Oops, IDK why i have those boolean lines in there:

Steal Lead Turn OOP
(cnt_chkchk_flop_bet_turn / cnt_chkchk_flop) * 100

cnt_
sum(if[holdem_hand_player_detail.val_p_raise_aggressor_pos < holdem_hand_player_statistics.position AND
holdem_hand_player_statistics.flg_p_face_raise AND NOT
holdem_hand_player_statistics.flg_p_3bet AND
holdem_hand_player_statistics.flg_f_check AND NOT
holdem_hand_player_statistics.flg_f_face_bet AND
holdem_hand_player_statistics.flg_t_bet, 1, 0])

cnt_chkchk_flop
sum(if[holdem_hand_player_detail.val_p_raise_aggressor_pos < holdem_hand_player_statistics.position AND
holdem_hand_player_statistics.flg_p_face_raise AND NOT
holdem_hand_player_statistics.flg_p_3bet AND
holdem_hand_player_statistics.flg_f_check AND NOT
holdem_hand_player_statistics.flg_f_face_bet, 1, 0])
madskills
 
Posts: 28
Joined: Mon May 19, 2008 7:42 pm

Re: Request for/help creating HU stats

Postby kraada » Sun Dec 21, 2008 11:49 am

The last incarnation looks like it should work properly to me.
kraada
Moderator
 
Posts: 54430
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Request for/help creating HU stats

Postby madskills » Sun Dec 21, 2008 2:02 pm

kraada wrote:The last incarnation looks like it should work properly to me.


Thx kraada.
Do the other two stats (C/R Flop Bet Turn & Delay CBet) look ok too?
madskills
 
Posts: 28
Joined: Mon May 19, 2008 7:42 pm

Re: Request for/help creating HU stats

Postby kraada » Sun Dec 21, 2008 6:14 pm

c/r flop, bet turn looks good.

The delayed cbet you've got a few things you need to fix or you won't end up with exactly the data you want.

Imagine you are sitting at a deep table and open raise on the button with two black aces, the small blind min-3bets, the big blind min 4-bets. You make a pot sized raise and both call. The flop is KQJ rainbow, and they check to you. Figuring that you're against a set often and you'll get more action from AK if you check a street, you elect to check behind (let's ignore whether that's a great play for the moment). The turn is a 4 and the small blind bets right out.

This hand is considered as a delayed cbet opportunity for you, and there are a couple of reasons why you wouldn't want it to:

(a) You exclude 3bet pots, so I imagine you want to exclude 4bet pots also.
(b) You need to not be facing a bet on the turn just in case someone donks at you; it's not really a delayed cbet opportunity then.

Other things I notice:
(c) You don't want to face a 3bet or 4bet on the flop either. Right now you're excluding facing bets, but if you had a hand same as above except the flop is bet and a raise to you, you're not facing a bet you're facing a raise.
(d) You also want to make sure you see the turn for a delay cbet opportunity. If you fold to a flop raise you don't want it to be counted as a delayed cbet either.


These stats can get awful tricky, so don't feel bad. More than once I've thought I had a stat down and realized that I'd missed a case or two.
kraada
Moderator
 
Posts: 54430
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Request for/help creating HU stats

Postby madskills » Sun Dec 21, 2008 7:13 pm

Thx again kraada, I was thinking thru these stats in mostly HU terms, so didn't think of all the possible scenarios.
Question: Delay CBet should really only be with position, as the line OOP normally represents something different in terms of hand ranges.
Is there a line of code I can include to isolate cases where the PFR has absolute position?
In the Steal stat I have guy calls preflop with position greater than PFR in the first line.
I cant see how to tweak that to get what I'm after...

PS: just to make sure I'm thinking correctly, can you confirm that the stat as originally coded will work as intended or HU play only?
EDIT: that is, after I tack on the line of code that removes spots where flop goes chkchk and BB bets the turn into us
madskills
 
Posts: 28
Joined: Mon May 19, 2008 7:42 pm

Next

Return to Custom Stats, Reports, and SQL [Read Only]

Who is online

Users browsing this forum: No registered users and 2 guests