I am trying to run gev (general extreme value) function in “evir” package. My 
data is divided by state. I am using the following codes but it is not working. 
I will appreciate any help.
 
#Split data
MAS <- split(MA, MA$states)
 
CP  <- lapply(MAS, function(x){gev(MAS$CP1, 100, method = "BFGS", control = 
list(maxit = 500))})
 
the Error message is:
 
Error in tapply(data, grouping, max) : arguments must have same length
 
I know there are also “by” function,  but I could not figure it out how to use 
it.

______________________________________________
R-help@r-project.org mailing list
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