I fit my CDF to sum of exponentials and now I want to take the numerical
derivative of this function to obtain probability density.I will really
appreciate your help reagrding the error messages I am getting which I don't
understand.

*
*

> fitterma <- function(xtime) {

a <- -0.09144115

b <- -0.01335756

c <- -2.368057

d <- -0.00600052

return(exp(a+b*xtime)+exp(c+d*xtime))

}


> numericDeriv(fitterma,"xtime")


*Error in numericDeriv(fitterma, "xtime") : *

*  cannot coerce type 'closure' to vector of type 'double'*

*
*

*Thanks,*

*parmee*

	[[alternative HTML version deleted]]

