% of the Pot bet on the Flop when won and lost the hand

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

% of the Pot bet on the Flop when won and lost the hand

Postby Th0rgal » Sun Jan 25, 2009 8:45 am

Need some help.

I would like to have a stat that tellse me the % of pot bet on flop, turn and river when they won and lost the hand.

I want to create it in a similar way then this stat:
Percentage of the Pot bet on the Flop
if( cnt_f_bet > 0 , amt_total_avg_f_bet / cnt_f_bet , 0 )

I think I need to create two new colums
cnt_f_bet_won and amt_total_avg_f_bet_won

With the new stat then being
Percentage of the Pot bet on the Flop when won
if( cnt_f_bet_won > 0 , amt_total_avg_f_bet_won / cnt_f_bet_won , 0 )


I have been trying to define these two colums but had no success so would need some help with this:
cnt_f_bet_won
tried:
sum(if[holdem_hand_player_statistics.flg_f_bet and holdem_hand_player_statistics.flg_won_hand = 1 , 1, 0])
and
sum(if[holdem_hand_player_statistics.flg_won_hand = 1 , holdem_hand_player_statistics.flg_f_bet, 0])

but get this "not a valid SQL Statement" when trying to validate

Any help much appreciated.
Thor
Th0rgal
 
Posts: 90
Joined: Sat Apr 19, 2008 7:45 am

Re: % of the Pot bet on the Flop when won and lost the hand

Postby kraada » Sun Jan 25, 2009 11:15 am

Thor,

You were pretty close!

sum(if[holdem_hand_player_statistics.flg_f_bet and holdem_hand_player_statistics.flg_won_hand , 1, 0])

Will count up how many times you bet the flop and won the hand.

Then you just need:

sum(if[holdem_hand_player_statistics.flg_won_hand, holdem_hand_player_detail.val_f_bet_made_pct, 0]) -- this is the sum of the percentage of the bets you made for hands you won.

Put hat over the first one (the number of times you bet the flop and won the hand), multiply by 100 and you should be all set.
kraada
Moderator
 
Posts: 54430
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: % of the Pot bet on the Flop when won and lost the hand

Postby Th0rgal » Sun Jan 25, 2009 11:51 am

Thank you Kraada,

one more quick question. for the lost % is it correct to

cnt_f_bet_lost
sum(if[holdem_hand_player_statistics.flg_f_bet and holdem_hand_player_statistics.flg_won_hand , 0, 0])
Change the "1" to a "0"


amt_total_avg_f_bet_lost
sum(if[holdem_hand_player_statistics.flg_won_hand, holdem_hand_player_detail.val_f_bet_made_pct, 1])

Change the "0" to a "1"

Thor
Th0rgal
 
Posts: 90
Joined: Sat Apr 19, 2008 7:45 am

Re: % of the Pot bet on the Flop when won and lost the hand

Postby kraada » Sun Jan 25, 2009 12:17 pm

No, what you want to use is NOT(holdem_hand_player_statistics.flg_won_hand)

The sum(if[X,1,0]) construction works like this:

Test if X is true, if it is, add 1, if isn't add 0. If you have it as ,0,0 nothing will ever get added, and ,0,1 would be true for all hands that you haven't both bet the flop and won the hand, which is very different than hands where you bet the flop and lost the hand (think about a hand where you didn't get to the flop).
kraada
Moderator
 
Posts: 54430
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: % of the Pot bet on the Flop when won and lost the hand

Postby preparac » Sun Dec 06, 2009 6:01 am

Is there a way to sort out bet-averages for different betting action, as for example for Cbets?
We do not have a field

holdem_hand_player_detail.val_f_cbet_made_pct

Is there possibly a work around?
preparac
 
Posts: 323
Joined: Thu May 15, 2008 6:23 am

Re: % of the Pot bet on the Flop when won and lost the hand

Postby WhiteRider » Sun Dec 06, 2009 6:11 am

You could do that like this: (pseudo code)
sum( if[ c-bet flop, amount bet, 0 ] )

i.e. If the player c-bet the flop add the amount they bet, else add 0.
WhiteRider
Moderator
 
Posts: 54025
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK

Re: % of the Pot bet on the Flop when won and lost the hand

Postby WhiteRider » Sun Dec 06, 2009 6:12 am

Actually, I have that..

sum( if[holdem_hand_player_statistics.flg_f_cbet, holdem_hand_player_detail.val_f_bet_made_pct, 0] )

Here I use the percentage of the pot bet rather than the absolute monetary amount because I think that is more relevant.
WhiteRider
Moderator
 
Posts: 54025
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK

Re: % of the Pot bet on the Flop when won and lost the hand

Postby preparac » Sun Dec 06, 2009 7:48 am

I got it, ty very much
preparac
 
Posts: 323
Joined: Thu May 15, 2008 6:23 am

Re: % of the Pot bet on the Flop when won and lost the hand

Postby WhiteRider » Sun Dec 06, 2009 9:30 am

No problem. :)
WhiteRider
Moderator
 
Posts: 54025
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK

Re: % of the Pot bet on the Flop when won and lost the hand

Postby preparac » Sun Dec 06, 2009 4:10 pm

I want to see how often a player folds to probe sized Cbet of < 50% of the pot.

But when i use the nominator
sum(if[tourney_holdem_hand_player_detail.val_f_bet_facing_pct < 50 AND tourney_holdem_hand_player_statistics.enum_f_cbet_action='F', 1, 0])

and the denominator
sum(if[tourney_holdem_hand_player_statistics.flg_f_cbet_def_opp AND tourney_holdem_hand_player_detail.val_f_bet_facing_pct < 50, 1, 0])

... it seems that this gives me all cases where the Cbet is less than 50% of the pot INCLUDING the amount of the Cbet . Is this possible or do I miss something here?
preparac
 
Posts: 323
Joined: Thu May 15, 2008 6:23 am

Next

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

Who is online

Users browsing this forum: No registered users and 0 guests