Replies: 1 comment
-
So I figured it has to do with position_map. I am not sure if the below code is still accurate for baseball.
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi I am new to all of this (python, git bash, and etc.) and I was able to successfully pull our free agents for our Fantasy Baseball league. But when pulling the eligible positions, they appear to be wrong.
I am using the below code
And I get back the following for Judge and Witt (top 2 free agents). Aaron Judge does not have 1B/3B position type, and Witt Jr doesn't have OF position type. The lineup slots are correct. Also, for players that have two positions, it only shows one of them.
Player Attributes:
name: Aaron Judge
playerId: 33192
position: 1B/3B
lineupSlot:
eligibleSlots: ['CF', 'OF', 'DH', 'UTIL', 'BE', 'IL']
acquisitionType: []
proTeam: NYY
injuryStatus: ACTIVE
stats: {0: {'points': 0.0, 'breakdown': {}, 'projected_points': 1018.0, 'projected_breakdown': {'AB': 520.0, 'H': 160.0, 'AVG': 0.308, '2B': 29.0, 'HR': 53.0, 'XBH': 82.0, '1B': 78.0, 'TB': 348.0, 'SLG': 0.669, 'B_BB': 121.0, 'B_IBB': 14.0, 'HBP': 6.0, 'SF': 3.0, 'SAC': 3.0, 'PA': 653.0, 'OBP': 0.442, 'OPS': 1.111, 'R': 117.0, 'RBI': 131.0, 'SB': 9.0, 'CS': 1.0, 'SB-CS': 8.0, 'GDP': 17.0, 'B_SO': 166.0, 'G': 146.0}}}
injured: False
total_points: 0.0
projected_total_points: 1018.0
Player Attributes:
name: Bobby Witt Jr.
playerId: 42403
position: OF
lineupSlot:
eligibleSlots: ['SS', '2B/SS', 'IF', 'UTIL', 'BE', 'IL']
acquisitionType: []
proTeam: KC
injuryStatus: ACTIVE
stats: {0: {'points': 0.0, 'breakdown': {}, 'projected_points': 1035.0, 'projected_breakdown': {'AB': 633.0, 'H': 193.0, 'AVG': 0.305, '2B': 40.0, '3B': 11.0, 'HR': 35.0, 'XBH': 86.0, '1B': 107.0, 'TB': 360.0, 'SLG': 0.569, 'B_BB': 49.0, 'B_IBB': 5.0, 'HBP': 7.0, 'SF': 8.0, 'SAC': 8.0, 'PA': 697.0, 'OBP': 0.357, 'OPS': 0.926, 'R': 112.0, 'RBI': 102.0, 'SB': 39.0, 'CS': 12.0, 'SB-CS': 27.0, 'GDP': 7.0, 'B_SO': 120.0, 'G': 155.0}}}
injured: False
total_points: 0.0
projected_total_points: 1035.0
Beta Was this translation helpful? Give feedback.
All reactions