GithubHelp home page GithubHelp logo

cricketr's Issues

Error reading player data for bowling stats

library(cricketr)
library(cricketdata)
murali_id = find_player_id("Muttiah Muralitharan")$ID
murali <- getPlayerData(murali_id,dir=".",file="murali.csv",type="bowling",homeOrAway=c(1,2), result=c(1,2,4))
warne_id = find_player_id("Shane Warne")$ID
warne <- getPlayerData(warne_id,dir=".",file="warne.csv",type="bowling",homeOrAway=c(1,2), result=c(1,2,4))
kumble_id = find_player_id("Anil Kumble")$ID
kumble <- getPlayerData(kumble_id,dir=".",file="kumble.csv",type="bowling",homeOrAway=c(1,2), result=c(1,2,4))

Output:

Registered S3 method overwritten by 'quantmod':
  method            from
  as.zoo.data.frame zoo
Error in if (n[2] == "BPO") { : missing value where TRUE/FALSE needed
Calls: getPlayerData
Execution halted

Venue and Result information

Thanks for this package
I'm about to release an alpha version of a shiny dashboard based on it

Would it be possible to return venue and result data as columns in the getPlayerData() function

Error Installing package

Hi Ganesh,

image

I get above error while installing package in R.

Any thought?

library(devtools)
install_github("tvganesh/cricketr")
Downloading GitHub repo tvganesh/cricketr@master
Error in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]) :
there is no package called ‘stringi’

Thanks,
Yogs

Discrepancy in number of games while using getTeamData

I was using the getTeamData function, as follows:

Screenshot 2023-05-11 at 15 08 42

For ODIs played by India, I get a data-frame of 986 observations.

Screenshot 2023-05-11 at 15 10 17

However, as of 11 May 2023, India has played 1029 ODIs, according to ESPNCricinfo Statsguru. What explains this discrepancy?

Screenshot 2023-05-11 at 15 09 23

Issue in batsmanDismissals()

First of all , I would like to appreciate your dedication in framing this package!. Hats Off!

Coming to the issues,
I have been trying to analyze Vijay Shankar's ODI dismissals. (http://stats.espncricinfo.com/ci/engine/player/477021.html?class=2;filter=advanced;orderby=start;template=results;type=batting;view=innings). and I came across 2 following issues:

(I have traced the function)

  1. batsman <- clean(file) .
    After execution of this line only one record stays in his data
    image
    image

Similarly with Rishab Pant
image
image

  1. If I manually remove the above line (batsman <- clean(file) and continue execution line by line, It looks like there is an issue that might occur with any player i.e The individual dismissal type % is calculated with denominator containing total no of innings played rather than total number of times dismissed

What I mean is that
His stats should read
Not out : 0 %
Run out : 40 %
Caught : 60 %
Refer
image

as opposed to current metrics displaying
Not out : 44%
Run out : 22%
Caught : 33%
image

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.