Creating advanced RFI stat

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

Creating advanced RFI stat

Postby pat3392 » Mon Jan 10, 2011 5:43 am

I have this idea for my HUD but having difficulties putting it together. I want to create 4 seperate stats of RFI, which will be different by position. RFI-EP would consist of the first 3 positions in a 10 max game, RFI-MP would be the next 3, RFI-LP would be CO/BTN and the last would be RFI-SB. The stats's colour will be depenednt on how often they fold to a 3-bet from any position; I haven't worked out the ranges yet. I also want the stats to change once they reach a certain M range, so the stats will change once one has crosses the 5/10/20 M boundary; there will be no less than 1 M boundary, nor any greater than 50 M boundary. It would be fantastic if the M was effective rather than players actual M size, not sure if this was possible. It would also be great if I could change the colour of the "show times/oppurtunities" based on the sample.

Can all of this be done? If so, could you please offer a walkthrough as to how to do it, whilst having in mind the only custom stat experience I have had is reading the guide and being a bit confused whilst doing so............. Thanks in advance ^^
pat3392
 
Posts: 142
Joined: Wed Jan 27, 2010 7:44 pm

Re: Creating advanced RFI stat

Postby kraada » Mon Jan 10, 2011 10:42 am

The short answer is that yes all of this can be done, but it's quite complex.

We've got several different pieces here so let's break it down:

Coloring - this is done per this post.

M-range columns - You'll need to make a column for each M-range for each stat that you want. So if you want 4 ranges of <5, 5-10, 10-20, 20+, you'll need 4 columns. Each column should be mostly the same except for the M expression - see here for more on how to build these expressions.

Changing value based on current M - This should be doable using the format tab - you'll want to do it as a nested if() statement, where you have something that looks like this: if(var_live_amt_stack / ( var_live_amt_bb + var_live_amt_sb + ( var_live_amt_ante * var_live_cnt_players ) ) < 5, (column_1 / column_2) * 100, if( var_live_amt_stack / ( var_live_amt_bb + var_live_amt_sb + ( var_live_amt_ante * var_live_cnt_players ) ) < 10, (column_3 / column_4) * 100, if( var_live_amt_stack / ( var_live_amt_bb + var_live_amt_sb + ( var_live_amt_ante * var_live_cnt_players ) ) < 20, (column_4 / column_5) * 100, (column_5 / column_6) * 100)))

The way this works is that it tests: if (X, then, otherwise) - if X is true, "then" is displayed, otherwise the "otherwise" bits happen. For more on the format tab, see this post.

It's definitely involved, but it should be doable. Writing up a click by click walkthrough would take forever, so I hope the shorthand is acceptable :)
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Creating advanced RFI stat

Postby pat3392 » Mon Jan 10, 2011 7:42 pm

Yeah that's more than acceptable :) thanks for the quick response btw ^^

ok information overload. Don't I first have to create the positional stats, then add the other codes/conditions to them?

EDIT: I just realised I may not have been clear about the positional stats. I don't want to use the preconfigured EP/MP/LP thingo, rather I want the LP to only represent open raises from the BTN/CO; so if we're 4-handed, EP/MP wouldn't be in effect. Did that make sense?
Last edited by pat3392 on Mon Jan 10, 2011 7:52 pm, edited 1 time in total.
pat3392
 
Posts: 142
Joined: Wed Jan 27, 2010 7:44 pm

Re: Creating advanced RFI stat

Postby kraada » Mon Jan 10, 2011 7:48 pm

Create the columns first, then combine them into the stat you want. Coloring you can actually do last, it was just the easiest to explain first :)
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Creating advanced RFI stat

Postby pat3392 » Mon Jan 10, 2011 8:46 pm

bump because of edit
pat3392
 
Posts: 142
Joined: Wed Jan 27, 2010 7:44 pm

Re: Creating advanced RFI stat

Postby pat3392 » Tue Jan 11, 2011 1:21 am

That code suggests that one cannot create an effective M; true?

That colour post doesn't mention changing the stats sample colour; it can't be done?
pat3392
 
Posts: 142
Joined: Wed Jan 27, 2010 7:44 pm

Re: Creating advanced RFI stat

Postby WhiteRider » Tue Jan 11, 2011 4:27 am

pat3392 wrote:That code suggests that one cannot create an effective M; true?

There is an effective stack database field (holdem_hand_summary.amt_p_effective_stack) which is based on information at the start of the hand.

That colour post doesn't mention changing the stats sample colour; it can't be done?

pat3392 wrote:It would also be great if I could change the colour of the "show times/oppurtunities" based on the sample.

You can't change the colour of part of the stat, the whole stat must be one colour – is that what you mean?
WhiteRider
Moderator
 
Posts: 53961
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK

Re: Creating advanced RFI stat

Postby pat3392 » Tue Jan 11, 2011 5:05 am

Hmmmm the M part sure looks hard

Sorry for my non-clear question. I figured it out though so no problems :)

I'm not sure if this can be done, but is it possible to "split" the HUD into 3 pieces? I've divided my HUD into 3 seperate groups, all of which are to be shown on table for everyone. I want to have 1 HUD to display VP$IP/PFR/hands/note editior, which would be placed on the top of the image, the players current M level on another HUD placed to the right/left and the more complex stats to be placed beneath the image. Make sense?
pat3392
 
Posts: 142
Joined: Wed Jan 27, 2010 7:44 pm

Re: Creating advanced RFI stat

Postby kraada » Tue Jan 11, 2011 9:50 am

That's exactly what different groups do - move the groups by right clicking and dragging to place them where you want and then PT Icon -> Save Layout to save the location for the future.

I do something similar with three groups (you can find my HUD in the repository).
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Creating advanced RFI stat

Postby pat3392 » Tue Jan 11, 2011 8:46 pm

Well I'm confused then. How do I make the seperate groups appear on the HUD? You've gave me the impression that I simply create the group, add the stats to be shown and it will show it self. I have done this and for some reason, the seperate groups aren't there. Am I missing a step?
pat3392
 
Posts: 142
Joined: Wed Jan 27, 2010 7:44 pm

Next

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

Who is online

Users browsing this forum: No registered users and 3 guests

cron
highfalutin