jldbc / pybaseball

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

statcast_sprint_speed Import Error #225

Closed jgamblin closed 3 years ago

jgamblin commented 3 years ago

I was attempting to look at the sprint speeds for this year using this example and end up getting this error:

ImportError: cannot import name 'statcast_sprint_speed' from 'pybaseball' (/usr/local/lib/python3.9/site-packages/pybaseball/__init__.py)

My Test Jupyter Notebook is here.

Screen Shot 2021-07-27 at 7 50 33 AM

schorrm commented 3 years ago

Whoopsy, idk what happened there. For the time being, you can use: from pybaseball.statcast_running import statcast_sprint_speed @wfordh what should be happening here? Is the doc wrong or is the code wrong?

wfordh commented 3 years ago

Hmm I'll look into it. I know when I was testing the other statcast pieces the imports were a little different than anticipated. Without looking, either what's in the example or what @schorrm suggested should work.

schorrm commented 3 years ago

Fixed in #228