Comments (4)
Hey Bill, I'm having trouble figuring out what 'boxscore formatted' means, especially since the Statcast data doesn't include batted ball outcomes, as far as I can tell. What output are you thinking of?
from baseballr.
Probably should have said pitch-by-pitch data, since the two are being collected and distributed generally together at this point. Basically the idea is to take the raw PITCHfx output and tag each outcome so that you can use the data to calculate custom metrics based on some grouping. So, wOBA for all pitches 95mph+ for LHH vs. LHP. Or group by batter and show their OPS on contact or on swings for a certain type of pitch, etc.
By boxscore format, I mean something along these lines:
Name Count X1B X2B X3B HR
I have some code that automatically tags each batted ball with a coding for single, double, triple, home run when I update my database, that might be a good jumping off point. This is based on the downloadable output you get from BaseballSavant.com:
savant_data$hit_type <- with(savant_data, ifelse(type == "X" & grepl("Single", savant_data$events), 1, ifelse(type == "X" & grepl("Double", savant_data$events), 2, ifelse(type == "X" & grepl("Triple", savant_data$events), 3, ifelse(type == "X" & grepl("Home Run", savant_data$events), 4, NA)))))
from baseballr.
Awesome, that makes way more sense, thanks!
from baseballr.
This will be available with the 0.3.3 release
from baseballr.
Related Issues (20)
- Fangraph batter splits using 'month'
- fg_batter_leaders splits using 'month' argument
- ncaa_game_logs issue with complete games
- NCAA 2023 Season Missing Data
- Better Documentation Around Fangraphs "Month" Parameter HOT 1
- When is Statcast PBP Data For Prev Day Games Available?
- Possible to update the data returned by load_umpire_ids()?
- Add fielding to ncaa_team_player_stats
- Name/Column Assignment HOT 1
- Scrape_savant_batter_all assigned name issue HOT 1
- Statcast Search (scrape_statcast_savant) Error: Can't assign 92 names to a 94-column data.table HOT 2
- statcast_search error: "Can't assign 92 names to a 94 column data.table" HOT 5
- ncaa_game_logs not working for type = "pitching" HOT 2
- statcast_search has broken due to batspeed and swing length being added HOT 16
- Do any of the functions in this package return the player height, weight, nationality, etc.? HOT 1
- additional request regarding statcast-search-minors
- statcast_search pitcher error: Error in setnames(x, value) Can't assign 92 names to a 94 column data.table HOT 1
- `ncaa_teams` function returns `NA` for every `team_id` HOT 1
- ncaa_team_player_stats() no Height & Handedness columns
- fg_pitcher_leaders HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from baseballr.