[R] plotting the cumulative hazard function of a process whose intensity function is specified

2013-04-11 Thread Elodie Gillain
I would like to simulate a stochastic process by specifying an intensity function, say lambda(t)=0.05 + 3  exp(−t) I have the following code, but it has a number of problems. One issue I have is I do not know where the time variable is. I would appreciate your help with this code.

[R] a function to compute the cumulative distribution function (cdf) of the gamma

2007-10-06 Thread elodie gillain
Dear Forum, I would need to write a function to calculate the cumulative distribution function (cdf) of the gamma random variable. I am allowed to use the following precoded functions: rgamma, pgamma, and dgamma. I am a little overwhelmed by this project, I am wondering how I should start.