Giter Club home page Giter Club logo

Comments (4)

afeierman avatar afeierman commented on July 24, 2024

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.

BillPetti avatar BillPetti commented on July 24, 2024

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.

afeierman avatar afeierman commented on July 24, 2024

Awesome, that makes way more sense, thanks!

from baseballr.

BillPetti avatar BillPetti commented on July 24, 2024

This will be available with the 0.3.3 release

from baseballr.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.