Hello,

I'm following an example in the book, analyzing baseball data with R, but it's 
not working for me. The example is:

compute.hr <- function(pid){d <- subset(Batting.60, playerID==pid)
sum(d$HR)}

Every time I try this, it says there's an unexpected symbol. Any idea on what 
the unexpected symbol is or how to fix it? Thanks.

______________________________________________
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to