Re: [R] Systematic resampling

2009-07-31 Thread Giovanni Petris
Dear all, This is the sequel to a question of mine a couple of days ago about how to implement systematic resampling from a discrete distribution efficiently. (See below the original question and description of the problem - the problem, in a nutshell, is how to draw N points from a discrete

[R] Systematic resampling (in sequential Monte Carlo)

2009-07-29 Thread Giovanni Petris
Dear all, Here is a little coding problem. It falls in the category of how can I do this efficiently? rather than how can I do this? (I know how to do it inefficiently). So, if you want to take the challenge, keep reading, otherwise just skip to the next post - I won't be offended by that ;-)