jldbc / pybaseball

Pull current and historical baseball statistics using Python (Statcast, Baseball Reference, FanGraphs)
MIT License
1.19k stars 324 forks source link

How to get game_id and starting lineups? #248

Open dwalton76 opened 2 years ago

dwalton76 commented 2 years ago

I can use schedule_and_record to download some basic info about games but how do I get the game-id for those games so that I can then use statcast_single_game?

Also how do I get the starting lineups for a game?

Thanks

ryan112358 commented 2 years ago

The function retrosheet.season_game_logs should give you lineup information. Alternatively, you could do some light post-processing of the output of statcast to determine it as well.

I'm not quite sure about your first question, might be able to combine info from gamedate and game_num from season-game_logs.