JoGall / soccermatics

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

Error on installation #5

Closed davidfombella closed 6 years ago

davidfombella commented 6 years ago
JoGall commented 6 years ago

Can you try reinstalling the package? I've overhauled the soccerSpokes() function and it seems to work now, at least for me.

davidfombella commented 6 years ago

Yes, now works. Please I send you a mail , trying to check if given x,y,time utc , you can help me to calculate speed,angle, acceleration to be able to test soccerSpokes and soccerFlow, it is raw data from stadium cameras.

davidfombella commented 6 years ago

Now error is on this file Error in .install_package_code_files(".", instdir) : files in 'Collate' field missing from 'C:/Users/dpomb/AppData/Local/Temp/RtmpWisOsT/devtools31a83d191083/JoGall-soccermatics-ff94e4e/R': pipe.R ERROR: unable to collate and parse R files for package 'soccermatics'

JoGall commented 6 years ago

The issue with pipe.R should be fixed now if you reinstall.

As for extracting speed and heading angle from raw x,y,t-data, see this gist for an example.

Speed is just the Pythogarian distance between successive x,y-points divided by the time interval, and heading angle can be calculated using atan2.

I may add a function to the package for calculating these soon.

davidfombella commented 6 years ago

On soccer spokes fails, since I have a time column Error in assert_all_white_list(data) : Column utc is of unsupported class POSIXlt/POSIXt

JoGall commented 6 years ago

Have you tried excluding the time column from your input data? i.e. soccerSpokes(data[,c("x", "y")])

The function shouldn't be handling time variables anyway so I'll update it soon.