jozefhajnala / nhlapi

A Minimum-Dependency R Interface to the NHL API
GNU Affero General Public License v3.0
30 stars 7 forks source link

initial pass at plot_rink #5

Closed MichaelChirico closed 3 years ago

MichaelChirico commented 4 years ago

Closes #4

Leaving it here for now. There are a few more bells and whistles that could be added:

But I wanted to stop here before I got too ambitious and pause for some feedback.

What else do you want out of the PR? I didn't add any tests (I never know what sorts of tests to add for plotting functionality)... I could add some "ad hoc" tests to this PR to show basic functionality?

Also note: I ~half-ran devtools::document(). I apparently have a newer version of roxygen2 than was used on the last build here, and the new version made a huge diff on other .Rd files. So I leave that to you to update first if you choose...

MichaelChirico commented 4 years ago

BTW here is the current output from plot_rink() Screenshot from 2020-09-04 15-15-28

MichaelChirico commented 4 years ago

Now with painted crease

Selection_001

MichaelChirico commented 4 years ago

Now with hash marks

Selection_002

MichaelChirico commented 4 years ago

With trapezoid

Selection_003

hswerdfe commented 3 years ago

Looks great: @MichaelChirico if I had a suggestion it would be to add in the actual net, and to put an alpha on blue shading for the crease and the net.

jozefhajnala commented 3 years ago

My apologies for taking like half a year, this is fantastic work! I just added a test and some vanity code style changes. Thank you very much for such a valuable contribution!

MichaelChirico commented 3 years ago

HTH Jozef!

@hswerdfe thanks! could you file as a follow-up issue?