Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Coordinate adjustments #106

Merged
merged 7 commits into from Mar 24, 2023
Merged

Coordinate adjustments #106

merged 7 commits into from Mar 24, 2023

Conversation

rossdrucker
Copy link
Collaborator

Noticed while debugging this issue that the ESPN coordinates that come from the API don't align with how the shot chart displays on the ESPN page. This PR transforms the coordinate system to the following:

  • Flipped x and y coordinates so court is horizontal (e.g. baskets along x axis)
  • Center of court corresponds to (0, 0)
  • Home team flipped to right side of court (i.e. +x), with y coordinates flipped to mirror the image on the ESPN page

Let me know what (if anything) needs to be adjusted here

@rossdrucker rossdrucker added the bug Something isn't working label Mar 22, 2023
@vercel
Copy link

vercel bot commented Mar 22, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated
hoopr ✅ Ready (Inspect) Visit Preview 💬 Add your feedback Mar 24, 2023 at 3:37AM (UTC)

@rossdrucker
Copy link
Collaborator Author

FWIW the only tests that are failing locally are the Kenpom functions

… throw locations; using coordinate_[x, y]_raw to indicate from-the-API coordinates and coordinate_[x, y] to represent transformed/aligned coordinates
@saiemgilani
Copy link
Collaborator

Made some updates to comply with tidyselect updates for the dplyr::rename portion of your coordinate alignment

@saiemgilani saiemgilani merged commit 124f8f1 into main Mar 24, 2023
4 checks passed
@saiemgilani saiemgilani deleted the coordinate-alignment branch March 24, 2023 03:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants