Page 1 of 12

AllinCalc for PT3 v0.96 (Updated 12/4)

PostPosted: Sat Jan 26, 2008 3:13 pm
by advis0r
Edit/Kraada: The newest version is available in this post

Hi,

in order to get familiar with the new PT3 database structure i updated my program for use with PT3 databases. it shows all allin pots, your equity and if u got (un)lucky.
1) be sure you have a java runtime installation ( version 6 recommended, get it at http://www.java.com )
2) extract zip into a new directory
3) edit settings.txt with your database info
4) run "run_allin_calc.bat"

Download: http://rapidshare.com/files/148842512/A ... 4.zip.html

Sample Output:
Code: Select all
[ 2006-12-20 23:01:35 ] [ Kc As ] [ 8s 9s ] [ Ts Ah 2s _ 3s 4h ] [ 0,6687 ] [   11,20$ /    7,49$ /    0,00$ /    -7,49$ ] [ FTP ] [ $0.50 NL (6 max) ]
...
[ 2008-01-04 16:31:47 ] [ Jd Jh ] [ Ks 8s ] [ 8h 4d Td _ 2h 8d ] [ 0,8141 ] [  158,06$ /  128,68$ /    0,00$ /  -128,68$ ] [ PTY ] [ $1 NL ]


found 501 headsup allin situations
won: 305 lost: 180 tied: 16
average potsize: 81,27$
average ev: 0,6214
money won: 25618,89$
money expected (based on allin equity): 26247,88$
money difference: -628,99$
max money diff: 2007-04-07 23:24:39 at +246,93$
min money diff: 2008-01-04 16:31:47 at -690,90$


Image

i used the following query:
Code: Select all
SELECT   summary.date_played,
         sites.site_abbrev AS site,
         limits.limit_name AS limit,
         hhh.id_hand,
         hero_d.holecard_1 AS hero_hc1,
         hero_d.holecard_2 AS hero_hc2,
         hero_d.amt_before AS hero_amt_before,
         hero_d.amt_bet_ttl AS hero_amt_bet_ttl,
         villain_d.holecard_1 AS villain_hc1,
         villain_d.holecard_2 AS villain_hc2,
         villain_d.amt_before AS villain_amt_before,
         villain_d.amt_bet_ttl AS villain_amt_bet_ttl,
         (CASE
            WHEN hero_s.enum_allin = 'N' THEN villain_s.enum_allin
            ELSE hero_s.enum_allin
          END) AS allin_street,
         history,
         card_1 AS flop1,
         card_2 AS flop2,
         card_3 AS flop3,
         card_4 AS turn,
         card_5 AS river,
         (amt_pot - amt_rake) AS potsize,
         hero_s.flg_won_hand AS hero_won,
         villain_s.flg_won_hand AS villain_won
FROM     player p,
         holdem_hand_player_detail hero_d,
         holdem_hand_player_detail villain_d,
         holdem_hand_player_statistics hero_s,
         holdem_hand_player_statistics villain_s,
         holdem_hand_summary summary,
         holdem_limit limits,
         lookup_sites sites,
         holdem_hand_histories hhh
WHERE    p.player_name = 'advis0r'
         AND hero_d.id_player = p.id_player
         AND hero_s.id_player = p.id_player
         AND villain_d.id_player != p.id_player
         AND villain_s.id_player != p.id_player
         AND summary.id_site != 0
         AND hhh.id_hand = hero_d.id_hand
         AND hhh.id_hand = hero_s.id_hand
         AND hhh.id_hand = villain_d.id_hand
         AND hhh.id_hand = villain_s.id_hand
         AND hhh.id_hand = summary.id_hand
         AND summary.id_limit = limits.id_limit
         AND summary.id_site = sites.id_site
         AND limits.flg_nlpl = true
         AND hero_s.flg_showdown = true
         AND villain_s.flg_showdown = true
         AND ((hero_d.amt_bet_p + hero_d.amt_bet_f + hero_d.amt_bet_t = villain_d.amt_before)
               OR (villain_d.amt_bet_p + villain_d.amt_bet_f + villain_d.amt_bet_t = hero_d.amt_before))
         AND ((SELECT COUNT(* )
               FROM   holdem_hand_player_statistics foo
               WHERE  foo.id_hand = hhh.id_hand
                      AND foo.flg_showdown = true) = 2)
ORDER BY summary.date_played


what do others who know SQL think about it?

Re: AllinCalc for PT3

PostPosted: Sat Jan 26, 2008 3:46 pm
by APerfect10
Very cool. I do not have time right now to look at your queries but I will definitely try to later...

Thanks for sharing this with us! :mrgreen:

Best regards,

Derek

Re: AllinCalc for PT3

PostPosted: Sat Jan 26, 2008 5:07 pm
by _dave_
Awesome.

Re: AllinCalc for PT3

PostPosted: Sat Jan 26, 2008 5:51 pm
by diesel007
Downloaded, extracted, in settings typed in my DB and screenname, PWD left =secret. Started run_allin_calc.bat and it says:Java is not an inside or outdise command, its not a porgram or file. To continue push any button.
LOL. COuld you help, pls? Thanks.
And also, after unzipping I've got directory LIB, 3 files + AllinCalc archive. Should I unzip it too?

Re: AllinCalc for PT3

PostPosted: Sat Jan 26, 2008 6:06 pm
by advis0r
[quote="diesel007"o3m]Downloaded, extracted, in settings typed in my DB and screenname, PWD left =secret. Started run_allin_calc.bat and it says:Java is not an inside or outdise command, its not a porgram or file. To continue push any button.
LOL. COuld you help, pls? Thanks.
And also, after unzipping I've got directory LIB, 3 files + AllinCalc archive. Should I unzip it too?[/quoteo3m]

looks like you dont have a java runtime environment installed. get it at http://www.java.com
and no, AllinCalc.jar must not be extracted.

Re: AllinCalc for PT3

PostPosted: Sat Jan 26, 2008 6:24 pm
by diesel007
Now I get mistake:
SQLException: ERROR: relation "player" does not exist
SQLState: 42P01
VendorError: 0
output.txt has been written.(I added this line of output.txt in settings myself)

But when I run Version 0.7 with the same set of settings it goes fine :(

Re: AllinCalc for PT3

PostPosted: Sat Jan 26, 2008 6:46 pm
by advis0r
did you point it to your [bqv1]pokertracker 3 database[/bqv1] in settings.txt?
NOT an old PT2 database.

Re: AllinCalc for PT3

PostPosted: Sat Jan 26, 2008 7:41 pm
by diesel007
Uhm, how to do that? What should I type in settings.txt?
And also, is there any difference in true results between V0.7 for PT2 and this one for PT3?
Thanks.

Re: AllinCalc for PT3

PostPosted: Sat Jan 26, 2008 8:07 pm
by Peligroso
Type the name of your database (found under database management in PT3, select the database and click edit, you'll see the actual database name in the "Database" field). Also, remember to put in your postgres username and password, as well as your screenname.

Re: AllinCalc for PT3

PostPosted: Sat Jan 26, 2008 8:11 pm
by diesel007
Oh, me, dummy. Got it.

highfalutin