Sample delta squared.

This function samples the initial number of changepoints from a sparse Poisson prior.

1 | ```
sampleK(mini, maxi, lambda, nb)
``` |

`mini` |
Minimum value. |

`maxi` |
Maximum value. |

`lambda` |
Parameter of the Poisson distribution. |

`nb` |
Number of values to sample. |

The sampled number of changepoints.

Sophie Lebre

For more information on the prior choice and sampling, see:

Dondelinger et al. (2012), "Non-homogeneous dynamic Bayesian networks with Bayesian regularization for inferring gene regulatory networks with gradually time-varying structure", Machine Learning.

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.