search for: sample_cpp

Displaying 5 results from an estimated 5 matches for "sample_cpp".

Did you mean: sample_app
2020 Jul 30
2
Seeding non-R RNG with numbers from R's RNG stream
...# get current state of RNG stream # first entry of .Random.seed is an integer representing the algorithm used # second entry is current position in RNG stream # subsequent entries are pseudorandom numbers seed_pos <- .Random.seed[2] seed <- .Random.seed[seed_pos + 2] out <- sample_cpp(init_var = init_var, seed = seed) # move R's position in the RNG stream forward by 1 with a throw away sample runif(1) # return the output out} [[alternative HTML version deleted]]
2020 Jul 30
3
Seeding non-R RNG with numbers from R's RNG stream
...ger representing the > algorithm used > > # second entry is current position in RNG stream > > # subsequent entries are pseudorandom numbers > > seed_pos <- .Random.seed[2] > > > > seed <- .Random.seed[seed_pos + 2] > > > > out <- sample_cpp(init_var = init_var, seed = seed) > > > > # move R's position in the RNG stream forward by 1 with a throw away > sample > > runif(1) > > > > # return the output > > out} > > > > [[alternative HTML version deleted]] > > &...
2020 Jul 30
0
Seeding non-R RNG with numbers from R's RNG stream
...first entry of .Random.seed is an integer representing the algorithm used > # second entry is current position in RNG stream > # subsequent entries are pseudorandom numbers > seed_pos <- .Random.seed[2] > > seed <- .Random.seed[seed_pos + 2] > > out <- sample_cpp(init_var = init_var, seed = seed) > > # move R's position in the RNG stream forward by 1 with a throw away sample > runif(1) > > # return the output > out} > > [[alternative HTML version deleted]] > > ______________________________________________...
2020 Jul 30
0
Seeding non-R RNG with numbers from R's RNG stream
...used > >? ? # second entry is current position in RNG stream > >? ? # subsequent entries are pseudorandom numbers > >? ? seed_pos <- .Random.seed[2] > > > >? ? seed <- .Random.seed[seed_pos + 2] > > > >? ? out <- sample_cpp(init_var = init_var, seed = seed) > > > >? ? # move R's position in the RNG stream forward by 1 with a > throw away sample > >? ? runif(1) > > > >? ? # return the output > >? ? out} > > > >? ? ? ?[[al...
2020 Jul 30
2
Seeding non-R RNG with numbers from R's RNG stream
...nd entry is current position in RNG stream > > > # subsequent entries are pseudorandom numbers > > > seed_pos <- .Random.seed[2] > > > > > > seed <- .Random.seed[seed_pos + 2] > > > > > > out <- sample_cpp(init_var = init_var, seed = seed) > > > > > > # move R's position in the RNG stream forward by 1 with a > > throw away sample > > > runif(1) > > > > > > # return the output > > > out} >...