Description Usage Arguments Value Author(s) See Also Examples
Calculate the expected event times of a non-homogeneous Poisson process.
1 | nhpp.mean.event.times(rate, num.events, prob.func, max.time = 1000)
|
rate |
The rate at which events occur in the Poisson process, aka lambda |
num.events |
Observe mean event times at this many points |
prob.func |
aka intensity function, function that takes time as sole argument and returns value between 0 and 1 |
max.time |
Maximum time value to use |
A vector of length num.events giving the expected times
Kristian Brock - Author, Daniel Slade - Contributor
nhpp.event.times
, nhpp.scenario
, hpp.mean.event.times
1 2 3 | intensity <- function(t) pmin(t/3, 1)
rate <- 10
nhpp.mean.event.times(rate, 50, prob.func = intensity)
|
[1] 0.7746192 1.0954615 1.3416542 1.5491802 1.7320272 1.8973495 2.0493734
[8] 2.1908612 2.3237557 2.4494536 2.5690103 2.6832461 2.7928136 2.8982421
[15] 2.9999976 3.0999976 3.1999976 3.2999976 3.3999976 3.4999976 3.5999976
[22] 3.6999976 3.7999976 3.8999976 3.9999976 4.0999976 4.1999976 4.2999976
[29] 4.3999976 4.4999976 4.5999976 4.6999976 4.7999976 4.8999976 4.9999976
[36] 5.0999976 5.1999976 5.2999976 5.3999976 5.4999976 5.5999976 5.6999976
[43] 5.7999976 5.8999976 5.9999976 6.0999976 6.1999976 6.2999976 6.3999976
[50] 6.4999976
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.