Columns verify, Stat verifies, HUD chokes with error. HALP!

Discuss how to create custom stats, reports and HUD profiles and share your creations.

Moderators: WhiteRider, kraada, Flag_Hippo, morny, Moderators

Columns verify, Stat verifies, HUD chokes with error. HALP!

Postby bodhisoma » Sun Sep 02, 2012 12:05 am

I've been working on this for hours, I'm completely stumped. All the columns enter correctly, the SQL verifies, the stat SQL verifies too, but when I go to use the stat in a HUD, I get:

Error: Expression: Invalid operation specified in expression.

I know this looks like a lot to weed through but I generated this with a php script so if the problem exists anywhere, it'll exists in the statistic definition or the first five column definitions since the file is generated by iterating over street & actions and spitting out the same stuff otherwise.

Code: Select all
COLUMNS

cnt_vpip_8_to_30bb
sum(if[(tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) > 8 AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) <= 30 AND tourney_hand_player_statistics.flg_vpip, 1, 0])

cnt_hands_8_to_30bb
sum(if[(tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) > 8 AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) <= 30 AND tourney_hand_player_statistics.id_hand > 8, 1, 0])

cnt_walks_8_to_30bb
sum(if[(tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) > 8 AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) <= 30 AND lookup_actions_p.action = '', 1, 0])

cnt_f_fold_8_to_30bb
sum(if[(tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) > 8 AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) <= 30 AND tourney_hand_player_statistics.flg_f_fold, 1, 0])

cnt_f_call_8_to_30bb
sum(if[if[tourney_hand_player_statistics.cnt_f_call > 0] AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) <= 30 AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) > 8, 1, 0])

cnt_f_bet_8_to_30bb
sum(if[(tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) > 8 AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) <= 30 AND tourney_hand_player_statistics.flg_f_bet, 1, 0])

cnt_f_raise_8_to_30bb
sum(if[if[tourney_hand_player_statistics.cnt_f_raise > 0] AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) <= 30 AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) > 8, 1, 0])

cnt_t_fold_8_to_30bb
sum(if[(tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) > 8 AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) <= 30 AND tourney_hand_player_statistics.flg_t_fold, 1, 0])

cnt_t_call_8_to_30bb
sum(if[if[tourney_hand_player_statistics.cnt_t_call > 0] AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) <= 30 AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) > 8, 1, 0])

cnt_t_bet_8_to_30bb
sum(if[(tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) > 8 AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) <= 30 AND tourney_hand_player_statistics.flg_t_bet, 1, 0])

cnt_t_raise_8_to_30bb
sum(if[if[tourney_hand_player_statistics.cnt_t_raise > 0] AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) <= 30 AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) > 8, 1, 0])

cnt_r_fold_8_to_30bb
sum(if[(tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) > 8 AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) <= 30 AND tourney_hand_player_statistics.flg_r_fold, 1, 0])

cnt_r_call_8_to_30bb
sum(if[if[tourney_hand_player_statistics.cnt_r_call > 0] AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) <= 30 AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) > 8, 1, 0])

cnt_r_bet_8_to_30bb
sum(if[(tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) > 8 AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) <= 30 AND tourney_hand_player_statistics.flg_r_bet, 1, 0])

cnt_r_raise_8_to_30bb
sum(if[if[tourney_hand_player_statistics.cnt_r_raise > 0] AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) <= 30 AND (tourney_hand_summary.amt_p_effective_stack / tourney_blinds.amt_bb) > 8, 1, 0])

STATS

RAFq 30 to 75bb
format_number(((((cnt_f_bet_30_to_75bb + cnt_f_raise_30_to_75bb + cnt_t_bet_30_to_75bb + cnt_t_raise_30_to_75bb + cnt_r_bet_30_to_75bb + cnt_r_raise_30_to_75bb) / (cnt_f_call_30_to_75bb + cnt_f_fold_30_to_75bb + cnt_t_call_30_to_75bb + cnt_t_fold_30_to_75bb + cnt_r_call_30_to_75bb + cnt_r_fold_30_to_75bb + cnt_f_bet_30_to_75bb + cnt_f_raise_30_to_75bb + cnt_t_bet_30_to_75bb + cnt_t_raise_30_to_75bb + cnt_r_bet_30_to_75bb + cnt_r_raise_30_to_75bb)) * 100) * ((cnt_vpip_30_to_75bb / (cnt_hands_30_to_75bb - cnt_walks_30_to_75bb)) * 100)) / 1000, 0, false, false)
bodhisoma
 
Posts: 231
Joined: Mon Sep 21, 2009 9:49 am

Re: Columns verify, Stat verifies, HUD chokes with error. H

Postby benharvey » Sun Sep 02, 2012 12:10 am

RAFq 30 to 75bb


I think you mean 8-30bb in this last bit of code, but I know that's just a typo.
benharvey
 
Posts: 35
Joined: Sun Apr 29, 2012 2:08 am

Re: Columns verify, Stat verifies, HUD chokes with error. H

Postby WhiteRider » Sun Sep 02, 2012 6:40 am

Nothing leaps out at me as being wrong there, but I suspect the problem will be in the stat expression.
Do you have that in the Value Expression or Format Expression, or both?

Please export your existing stat before making any changes, so that you can get back to where you are now, before doing anyhing else!

Do the calculations in the Value Expression (without the 'format_number) and set the Format to "Number".
Try a simple version of that stat expression, starting with just one of your columns and make sure that works OK.
If so, build up the expression in stages to make sure the structure is OK.

If you can't work out what is wrong attach your stat to a Support Ticket and we'll take a look at it for you.
WhiteRider
Moderator
 
Posts: 54017
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK

Re: Columns verify, Stat verifies, HUD chokes with error. H

Postby bodhisoma » Sun Sep 02, 2012 10:38 am

Thanks Whiterider, I'll give that a shot in a few minutes.

Say, are there any plans for PT4 to accept a flat file for column/stat import, or perhaps a tool that will turn a flat file into a proper .pt4stat file?
bodhisoma
 
Posts: 231
Joined: Mon Sep 21, 2009 9:49 am

Re: Columns verify, Stat verifies, HUD chokes with error. H

Postby bodhisoma » Sun Sep 02, 2012 11:54 am

WhiteRider wrote:Do you have that in the Value Expression or Format Expression, or both?


I have it in Value Expression, which appears under the T > Players > Stats > Definition tab.

I can't actually find anything labeled "Format Expression." Do you mean "Detailed Description" under the Details tab?

WhiteRider wrote:Do the calculations in the Value Expression (without the 'format_number) and set the Format to "Number".


The good news is, that worked.

The bad news is ...well, there's a lot of it.

First, a HUD created with this stat displays only sometimes, meaning the entire block doesn't come up. No background, no numbers, no text, no nothing. Actually "never" on a newly-created HUD. I tried adding a new group to an existing HUD, adding the stat, still nothing. I then tried adding the stat to a HUD group that was already displaying, now it shows up, now it displays completely bizarre info, something like 10,000 or 8,333. This is bizarre because it's like the software isn't seeing the /1000 that is in the stat definition itself.

FWIW, the stat (RAFq) is, in a nutshell, just ( AFq * VPIP ) / 1000. So a villain with an AFq of 30 and a VPIP of 60 should have an RAFq of 1.8 with a max possible of 10.

I've tried restarting PT4 during multiple points in this process. no luck. In fact now that I've restarted PT4 this time, the piggybacking is no longer working, that HUD group no longer displays.

I should mention that I upgraded to 3GB of RAM a month or two ago.

I'll try plugging away at it a bit more and submit a ticket if I can't get it figured out.
bodhisoma
 
Posts: 231
Joined: Mon Sep 21, 2009 9:49 am

Re: Columns verify, Stat verifies, HUD chokes with error. H

Postby bodhisoma » Sun Sep 02, 2012 12:02 pm

I just realized that even though I save the stat as "format type: number", and save, if I leave and come back, it has reverted to "Format Type: Expression."

WTH.
bodhisoma
 
Posts: 231
Joined: Mon Sep 21, 2009 9:49 am

Re: Columns verify, Stat verifies, HUD chokes with error. H

Postby bodhisoma » Sun Sep 02, 2012 12:11 pm

Ah, I feel like a dope.

I was having problems with it not displaying at all because later on in my testing, I was "replay[ing] all hands in report" and of course the first hand doesn't have any HUD data to display. Cycling to the next hand displays the HUD.

As for the oddball information, this was due to me accidentally clipping out the /1000 when I removed the formatting portion of the definition.

Seems to be displaying fine now, will work on it through the day and repost the results later. I'm guessing this is solved.
bodhisoma
 
Posts: 231
Joined: Mon Sep 21, 2009 9:49 am

Re: Columns verify, Stat verifies, HUD chokes with error. H

Postby bodhisoma » Sun Sep 02, 2012 12:15 pm

Everything looks awesome so far, there's only one problem I'm having now; in the HUD profile editor, I can't edit the Color Ranges. It's greyed out.
bodhisoma
 
Posts: 231
Joined: Mon Sep 21, 2009 9:49 am

Re: Columns verify, Stat verifies, HUD chokes with error. H

Postby WhiteRider » Sun Sep 02, 2012 4:12 pm

It seems that you've got it worked out, but to clarify: by "format expression" I meant "format type", with Expression selected.

In the Profile Editor the Color Ranges option should be enabled for all numeric stats, but is disabled for text stats (like player name, which may be selected by default as the first stat in a Hud) or 'special' stats like the Note Editor, as color ranges don't make sense for non-numeric values.
Is is still disabled when you click on your new stat?
Does your new stat use Format Type: Number (or it may show Format Type: Expression with a format_number expression).
WhiteRider
Moderator
 
Posts: 54017
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK

Re: Columns verify, Stat verifies, HUD chokes with error. H

Postby bodhisoma » Sun Sep 02, 2012 4:14 pm

bodhisoma wrote:Everything looks awesome so far, there's only one problem I'm having now; in the HUD profile editor, I can't edit the Color Ranges. It's greyed out.


Anyone know of a reason why color definitions would be greyed out?
bodhisoma
 
Posts: 231
Joined: Mon Sep 21, 2009 9:49 am

Next

Return to Custom Stats, Reports and HUD Profiles

Who is online

Users browsing this forum: No registered users and 6 guests

cron
highfalutin