Little more help with creating HU stats please

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

Little more help with creating HU stats please

Postby madskills » Thu Jan 08, 2009 10:08 am

This one just gives me weird numbers:
Should be -
Button opens, gets called by BB, does NOT cbet the flop, and folds to a turn lead from BB

Fold to Turn Steal
(cnt_fold_to_turn_stl / cnt_fold_to_turn_stl_opp) * 100

cnt_fold_to_turn_stl
sum(if[holdem_hand_player_detail.flg_f_has_position AND
holdem_hand_player_statistics.flg_p_open AND NOT
holdem_hand_player_statistics.flg_p_3bet_def_opp AND NOT
holdem_hand_player_statistics.flg_f_3bet_opp AND
holdem_hand_player_statistics.flg_f_check AND
holdem_hand_player_statistics.flg_t_3bet_opp AND
holdem_hand_player_statistics.flg_t_fold, 1, 0])

cnt_fold_to_turn_stl_opp
sum(if[holdem_hand_player_detail.flg_f_has_position AND
holdem_hand_player_statistics.flg_p_open AND NOT
holdem_hand_player_statistics.flg_p_3bet_def_opp AND NOT
holdem_hand_player_statistics.flg_f_3bet_opp AND
holdem_hand_player_statistics.flg_f_check AND
holdem_hand_player_statistics.flg_t_3bet_opp, 1, 0])

The next one is self-explanitory and seems to be giving me good numbers per buyin (i.e. 1knl, 600nl) but then when the levels are added together at the bottom of the General Tab it just gives 100%.

Delay CBet
(cnt_delay_cbet_turn / cnt_delay_cbet_turn_opp) * 100

cnt_delay_cbet_turn
sum(if[holdem_hand_player_detail.flg_f_has_position AND
holdem_hand_player_statistics.flg_p_open AND NOT
holdem_hand_player_statistics.flg_p_3bet_def_opp AND NOT
holdem_hand_player_statistics.flg_f_3bet_opp AND
holdem_hand_player_statistics.flg_f_check AND NOT
holdem_hand_player_statistics.flg_t_3bet_opp AND
holdem_hand_player_statistics.flg_t_bet, 1, 0])

cnt_delay_cbet_turn_opp
sum(if[holdem_hand_player_detail.flg_f_has_position = TRUE AND
holdem_hand_player_statistics.flg_p_open AND
(holdem_hand_player_statistics.flg_p_3bet_def_opp AND NOT
holdem_hand_player_statistics.flg_f_3bet_opp AND
holdem_hand_player_statistics.flg_f_check AND NOT
holdem_hand_player_statistics.flg_t_3bet_opp, 1, 0])

Thanks so much!
madskills
 
Posts: 28
Joined: Mon May 19, 2008 7:42 pm

Re: Little more help with creating HU stats please

Postby kraada » Thu Jan 08, 2009 11:40 am

A few things:

For the first stat:

Open is being the first to put money into the pot, not an open raise. If you want a preflop raise from the button, you can either add AND NOT holdem_hand_player_statistics.flg_p_limp (this removing the open-limp option) or add AND holdem_hand_player_statistics.cnt_p_raise > 0 (that you actually did raise). Either should work heads up.

I'm not sure why you have the no flop 3bet opporunity. If you aren't cbetting you can't have a 3bet opportunity heads up by definition.

You also have a 3bet opportunity on the turn, and you really don't want that. The only way you get a 3bet opportunity post flop heads up is if you bet and get raised. You just want your action facing a turn bet to be a fold, so use substring(lookup_actions_t.action from 1 for 1 = 'F') which makes sure your first turn action is a fold (which it can't be unless you're facing a bet).

For the opportunity, use holdem_hand_player_detail.amt_t_bet_facing > 0 to determine that you face a turn bet.

For the second stat:

The 3bet stuff still applies; I'm really not sure why you're trying to check for no 3bets in all of these spots; could you explain your reasoning here?
kraada
Moderator
 
Posts: 54430
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Little more help with creating HU stats please

Postby WhiteRider » Thu Jan 08, 2009 5:23 pm

kraada wrote:If you want a preflop raise from the button, you can either add AND NOT holdem_hand_player_statistics.flg_p_limp (this removing the open-limp option) or add AND holdem_hand_player_statistics.cnt_p_raise > 0 (that you actually did raise).

Or you could use the 'steal' field..
holdem_hand_player_statistics.flg_steal_att
If you're playing heads up this will have to be from the button/SB, and it would take out the need for a couple of other fields.
WhiteRider
Moderator
 
Posts: 54025
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK

Re: Little more help with creating HU stats please

Postby madskills » Thu Jan 08, 2009 5:29 pm

Wowwww...
I am so sorry for wasting your time.
Posted that before I left to go snowboarding and was rushed.
Again, very sorry.

***************************
Delay CBet Turn

Player has postion and
Raises preflop and
does not get 3bet and
does not face a flop bet and
chks the flop and
does not face a turn bet and
bets the turn

sum(if[holdem_hand_player_detail.flg_f_has_position AND
holdem_hand_player_statistics.cnt_p_raise > 0 AND NOT
holdem_hand_player_statistics.flg_p_3bet_def_opp AND NOT
holdem_hand_player_detail.amt_f_bet_facing > 0 AND
holdem_hand_player_statistics.flg_f_check AND NOT
holdem_hand_player_detail.amt_t_bet_facing > 0 AND
holdem_hand_player_statistics.flg_t_bet, 1, 0])

Fold to Turn Steal

Player has position and
raises preflop and
does not get 3bet and
does not face a flop bet and
checks the flop and
faces a turn lead and
folds to the bet

sum(if[holdem_hand_player_detail.flg_f_has_position AND
holdem_hand_player_statistics.cnt_p_raise > 0 AND NOT
holdem_hand_player_statistics.flg_p_3bet_def_opp AND NOT
holdem_hand_player_detail.amt_f_bet_facing > 0 AND
holdem_hand_player_statistics.flg_f_check AND
holdem_hand_player_detail.amt_t_bet_facing > 0 AND
holdem_hand_player_statistics.flg_t_fold, 1, 0])

I think those look ok?
Questions:

- Is the cnt.p.raise > 0 checking if the player in question raised or if anyone in the hand raised
- In Fold to turn stl, am i going to have any issues with the turn going bet/raise/allin/fold
- If both these are ok, any idea why im getting 100% for all stakes in my general tab for both stats? (all per stake numbers for both are between 0 and 100.

Thanks so much and again, myapologies for the ridic post above.
madskills
 
Posts: 28
Joined: Mon May 19, 2008 7:42 pm

Re: Little more help with creating HU stats please

Postby kraada » Thu Jan 08, 2009 6:48 pm

It all looks good except for one minor point:

using flg_t_fold will get you times you fold ever on the turn. So if you raise his lead, and he 3bets and you fold, that would get counted also.

If you use the value: substring(lookup_action_t.action from 1 for 1 = 'F')
then it will mean that you've made your exact first action as a fold.

You will need to be using Beta 23 for this stat to function, though.

Otherwise, everything else looks good.
kraada
Moderator
 
Posts: 54430
Joined: Wed Mar 05, 2008 2:32 am
Location: NY


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

Who is online

Users browsing this forum: No registered users and 0 guests