Raked hands stat in HUD

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

Raked hands stat in HUD

Postby grt2001 » Thu Aug 27, 2009 5:45 am

Hello,
I created a report listing the hands that I contributed money to that were raked by the poker site (background: I wanted to keep track of how many hands in each session were raked to know the status of absolute status points /session):

I used the following fields:

Hand#
Date Summary
Winner
Amount won
Pot
Rake

Under the filters I have the following conditional statement:

flg_blind_b = false AND flg_blind_s = false AND holdem_hand_player_detail.amt_bet_ttl > 0 AND amt_pot >0.19
OR flg_blind_b = true AND holdem_hand_player_detail.amt_bet_ttl >= 0.02 AND amt_pot >0.19
OR flg_blind_s = true AND holdem_hand_player_detail.amt_bet_ttl >= 0.01 AND amt_pot >0.19

because I want to count any hand, where I'm:

either in the small or big blind, or betting, and where the pot reaches at least 20cts.

The summary below the report shows me how many hands meet these conditions.


Now, I would actually like to create a custom statistic that shows me this number (# raked hands, where I paid money) in the hud, but I'm having trouble getting this translated into valid SQL. Can anyone help?

Thanks,
Geert
grt2001
 
Posts: 34
Joined: Mon Mar 03, 2008 1:52 pm

Re: Raked hands stat in HUD

Postby WhiteRider » Thu Aug 27, 2009 6:06 am

You would need to create a column to count up the number of times the situation arises - if you add this to the HUD for yourself then it will always show just those times from the current table.

The column and stat you use to display it will have to be in the Holdem Cash Player Statistics section.

You shouldn't need to actually check for being in a blind explicitly because you only want to know whether or not you contributed to the pot, and if you were in a blind then you would have bet.
So a check for holdem_hand_player_detail.amt_bet_ttl > 0 should be good enough, along with a check for holdem_hand_summary.amt_pot > 0.19.

So your column's expression only needs to be:
sum ( if[ holdem_hand_player_detail.amt_bet_ttl > 0.19 AND holdem_hand_player_detail.amt_bet_ttl > 0, 1, 0 ] )

Then just create a new Statistic to display your column's value.

Have a look at the Custom Stats guide and Custom Statistics and Reports FAQ for examples.
WhiteRider
Moderator
 
Posts: 54025
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK

Re: Raked hands stat in HUD

Postby grt2001 » Thu Aug 27, 2009 6:25 am

Thanks!

Cheers,
Geert
grt2001
 
Posts: 34
Joined: Mon Mar 03, 2008 1:52 pm

Re: Raked hands stat in HUD

Postby grt2001 » Thu Aug 27, 2009 7:39 am

sum ( if[ holdem_hand_summary.amt_pot > 0.19 AND holdem_hand_player_detail.amt_bet_ttl > 0, 1, 0 ] )

Methinks actually, ...correct?

Cheers, Geert
grt2001
 
Posts: 34
Joined: Mon Mar 03, 2008 1:52 pm

Re: Raked hands stat in HUD

Postby grt2001 » Thu Aug 27, 2009 8:13 am

Works like a charm, thnx again.

Cheers,
Geert
grt2001
 
Posts: 34
Joined: Mon Mar 03, 2008 1:52 pm

Re: Raked hands stat in HUD

Postby WhiteRider » Thu Aug 27, 2009 9:44 am

grt2001 wrote:sum ( if[ holdem_hand_summary.amt_pot > 0.19 AND holdem_hand_player_detail.amt_bet_ttl > 0, 1, 0 ] )

Methinks actually, ...correct?

Cheers, Geert

Sorry - you're quite right. I copy&pasted and obviously didn't update the second one.
WhiteRider
Moderator
 
Posts: 54025
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK

Re: Raked hands stat in HUD

Postby mykel99945 » Sun Oct 11, 2009 7:24 am

I was looking to make a stat for the same thing, but I'm not sure this stat is entirely correct. I believe most online sites use the "No Flop No Drop" rule, meaning if it's folded pre-flop there is no rake, so the hand shouldn't count in your stat. In the case where there were a couple of limpers and a raise and then folds, or a raise and a reraise, then all folds, I think your stat would capture them if the pot was over 19c.

Am I correct about this?
mykel99945
 
Posts: 2
Joined: Tue Sep 30, 2008 8:11 pm

Re: Raked hands stat in HUD

Postby kraada » Sun Oct 11, 2009 8:40 am

I believe you are correct.

Add in:
AND holdem_hand_summary.cnt_players_f > 0
to ensure that someone saw a flop.

So the final column should read:

sum ( if[ holdem_hand_summary.amt_pot > 0.19 AND holdem_hand_player_detail.amt_bet_ttl > 0 and holdem_hand_summary.cnt_players_f > 0, 1, 0 ] )
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