JoGall / soccermatics

Tools for visualisation and analysis of soccer tracking and event data
308 stars 36 forks source link

Issue producing some chart types #21

Closed chrisbaker108 closed 5 years ago

chrisbaker108 commented 5 years ago

Hi, Thanks for your work on the package,

When I try to make some of charts I get errors.

When I follow the code on this issue (https://github.com/JoGall/soccermatics/issues/14) I get this error when plotting the passmap, but the shot map works.

Error: Column id can't be used as a grouping variable because it's a tbl_df/tbl/data.frame

When plotting heatmaps I get this error "Error in is.finite(x) : default method not implemented for type 'list'"

Not sure where I'm going wrong and would really appreciate any pointers!

chrisbaker108 commented 5 years ago

Thing the error was trying to plot multiple games of data on the plots designed for single games. Apologies!

LucaMino35 commented 4 years ago

Hi chrisbaker108, sorry to disturb you. I am having the same your issues with the package, but I cannot fix the issue yet. Could you be so nice to help me? Thank you in advance

chrisbaker108 commented 4 years ago

Hi Luca, The 'issue' I had was that some of the plots are only for single games (such as the passmap), whilst others work for multiple games (like the shotmap). If you try to plot data from multiple games on the passmap it won't work, as that plot wouldn't make sense. You can filter the data to be just one game first, then it works.

LucaMino35 commented 4 years ago

Ok got it, but isn't statsbomb data related to the single match Fra - Arg? I can't understand which is the variable to filter in order to count for one match only, as to me the whole dataframe seems to refer to one single match (match id is always 7580)... sorry.

freddielloyd commented 4 years ago

Hi both, Chris I am receiving the exact same error message for the passmap, but I am 100% not trying to plot multiple games of data on the plot, I am passing data frames with a single match. Any ideas as to what else might be causing it/ what cause your solution to work?

freddielloyd commented 4 years ago

I should add that similar to you I am able to produce shotmaps with no issue