Closed mprofumo closed 2 years ago
Yeah I get this too. I think it has something to do with the venues having inconsistent whitespace. I wrote some Python code that sucks it out correctly.
I also found a temporary solution by commenting out the assigned column types in readr::read_fwf()
match_data <- readr::read_fwf(url_text,
skip = 2,
col_positions = cols,
# col_types = c("dcccccccc")
)
Hi @mprofumo I'm not able to replicate this locally.
library(fitzRoy)
results <- fetch_results_afltables(2021)
unique(results$Away.Team)
#> [1] "Carlton" "Footscray" "Fremantle" "Geelong"
#> [5] "Hawthorn" "Sydney" "Port Adelaide" "St Kilda"
#> [9] "Gold Coast" "Collingwood" "Brisbane Lions" "Adelaide"
#> [13] "Essendon" "Melbourne" "North Melbourne" "Richmond"
#> [17] "West Coast" "GWS"
Created on 2021-10-14 by the reprex package (v2.0.0)
Are you able to confirm that this is still an issue for you? If so, I might need you to produce another reprex with your session info (you can do this with reprex::reprex(session_info = TRUE)
after you've copied your code).
Hi @mprofumo @zeldir just reviewing some old bugs and noticed I can't reproduce this. If you could confirm it is still an issue (ideally with a reproducable example) that'd be awesome.
It may have been fixed by some related work
Hi Jimmy,
I have updated everything and now using new commands, and this works well:
res = fetch_results(2010:2021) res <- apply(res,2,as.character) write.csv(res, "results_afl.csv")
I think I'll move to the AFL data because it's all the same as the fixture.
Thanks! Lach
On Wed, 12 Jan 2022 at 11:51, James Day @.***> wrote:
Hi @mprofumo https://github.com/mprofumo @zeldir https://github.com/zeldir just reviewing some old bugs and noticed I can't reproduce this. If you could confirm it is still an issue (ideally with a reproducable example) that'd be awesome.
It may have been fixed by some related work
— Reply to this email directly, view it on GitHub https://github.com/jimmyday12/fitzRoy/issues/161#issuecomment-1010437920, or unsubscribe https://github.com/notifications/unsubscribe-auth/AQTNZTQRHFJP2XJDDQ4FDL3UVSX5XANCNFSM5DWFJ4PA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.
You are receiving this because you were mentioned.Message ID: @.***>
It looks like there is an issue parsing the raw data from AFL tables with scores ending up in team names, e.g Away.Team being "3.7.85".
Thanks for the hard work!