[NEWIMPORT] HandsPlayers.sawShowdown added
This commit is contained in:
parent
dc1b0d2e38
commit
9203e0b0d8
|
@ -1402,6 +1402,7 @@ class Database:
|
||||||
pdata[p]['street2Seen'],
|
pdata[p]['street2Seen'],
|
||||||
pdata[p]['street3Seen'],
|
pdata[p]['street3Seen'],
|
||||||
pdata[p]['street4Seen'],
|
pdata[p]['street4Seen'],
|
||||||
|
pdata[p]['sawShowdown'],
|
||||||
pdata[p]['street0Aggr'],
|
pdata[p]['street0Aggr'],
|
||||||
pdata[p]['street1Aggr'],
|
pdata[p]['street1Aggr'],
|
||||||
pdata[p]['street2Aggr'],
|
pdata[p]['street2Aggr'],
|
||||||
|
@ -1430,6 +1431,7 @@ class Database:
|
||||||
street2Seen,
|
street2Seen,
|
||||||
street3Seen,
|
street3Seen,
|
||||||
street4Seen,
|
street4Seen,
|
||||||
|
sawShowdown,
|
||||||
street0Aggr,
|
street0Aggr,
|
||||||
street1Aggr,
|
street1Aggr,
|
||||||
street2Aggr,
|
street2Aggr,
|
||||||
|
@ -1438,6 +1440,7 @@ class Database:
|
||||||
wonWhenSeenStreet1
|
wonWhenSeenStreet1
|
||||||
)
|
)
|
||||||
VALUES (
|
VALUES (
|
||||||
|
%s,
|
||||||
%s, %s, %s, %s, %s,
|
%s, %s, %s, %s, %s,
|
||||||
%s, %s, %s, %s, %s,
|
%s, %s, %s, %s, %s,
|
||||||
%s, %s, %s, %s, %s,
|
%s, %s, %s, %s, %s,
|
||||||
|
@ -1450,7 +1453,6 @@ class Database:
|
||||||
# startCards,
|
# startCards,
|
||||||
# street0_3BChance,
|
# street0_3BChance,
|
||||||
# street0_3BDone,
|
# street0_3BDone,
|
||||||
# sawShowdown,
|
|
||||||
# wonAtSD,
|
# wonAtSD,
|
||||||
# otherRaisedStreet1,
|
# otherRaisedStreet1,
|
||||||
# otherRaisedStreet2,
|
# otherRaisedStreet2,
|
||||||
|
|
|
@ -44,6 +44,7 @@ class DerivedStats():
|
||||||
self.handsplayers[player[1]]['street4Seen'] = False
|
self.handsplayers[player[1]]['street4Seen'] = False
|
||||||
self.handsplayers[player[1]]['street4Aggr'] = False
|
self.handsplayers[player[1]]['street4Aggr'] = False
|
||||||
self.handsplayers[player[1]]['wonWhenSeenStreet1'] = False
|
self.handsplayers[player[1]]['wonWhenSeenStreet1'] = False
|
||||||
|
self.handsplayers[player[1]]['sawShowdown'] = False
|
||||||
|
|
||||||
self.assembleHands(self.hand)
|
self.assembleHands(self.hand)
|
||||||
self.assembleHandsPlayers(self.hand)
|
self.assembleHandsPlayers(self.hand)
|
||||||
|
@ -100,6 +101,8 @@ class DerivedStats():
|
||||||
|
|
||||||
def assembleHandsPlayers(self, hand):
|
def assembleHandsPlayers(self, hand):
|
||||||
#street0VPI/vpip already called in Hand
|
#street0VPI/vpip already called in Hand
|
||||||
|
# sawShowdown is calculated in playersAtStreetX, as that calculation gives us a convenient list of names
|
||||||
|
|
||||||
#hand.players = [[seat, name, chips],[seat, name, chips]]
|
#hand.players = [[seat, name, chips],[seat, name, chips]]
|
||||||
for player in hand.players:
|
for player in hand.players:
|
||||||
self.handsplayers[player[1]]['seatNo'] = player[0]
|
self.handsplayers[player[1]]['seatNo'] = player[0]
|
||||||
|
@ -193,7 +196,11 @@ class DerivedStats():
|
||||||
self.hands['playersAtStreet%d' % (i+1)] = len(set.union(alliners, actors))
|
self.hands['playersAtStreet%d' % (i+1)] = len(set.union(alliners, actors))
|
||||||
|
|
||||||
actions = hand.actions[hand.actionStreets[-1]]
|
actions = hand.actions[hand.actionStreets[-1]]
|
||||||
self.hands['playersAtShowdown'] = len(set.union(self.pfba(actions) - self.pfba(actions, l=('folds',)), alliners))
|
pas = set.union(self.pfba(actions) - self.pfba(actions, l=('folds',)), alliners)
|
||||||
|
self.hands['playersAtShowdown'] = len(pas)
|
||||||
|
|
||||||
|
for player in pas:
|
||||||
|
self.handsplayers[player]['sawShowdown'] = True
|
||||||
|
|
||||||
def streetXRaises(self, hand):
|
def streetXRaises(self, hand):
|
||||||
# self.actions[street] is a list of all actions in a tuple, contining the action as the second element
|
# self.actions[street] is a list of all actions in a tuple, contining the action as the second element
|
||||||
|
|
Loading…
Reference in New Issue
Block a user