# NOT RUN {
# }
# NOT RUN {
# Both home and away. Result = won,lost and drawn
sehwag <-getPlayerDataOD(35263,dir="../cricketr/data", file="sehwag1.csv",
type="batting", homeOrAway=c(1,2),result=c(1,2,3,5))
# Only away. Get data only for won and lost innings
sehwag <-getPlayerDataOD(35263,dir="../cricketr/data", file="sehwag2.csv",
type="batting",homeOrAway=c(2),result=c(1,2))
# Get bowling data and store in file for future
malinga <- getPlayerData(49758,dir="../cricketr/data",file="malinga1.csv",
type="bowling")
# Get Dhoni's ODI record in Australia against Australua
dhoni <- getPlayerDataOD(28081,opposition = 2,host=2,dir=".",
file="dhoniVsAusinAusOD",type="batting")
# }
Run the code above in your browser using DataLab