search for: get_seed

Displaying 4 results from an estimated 4 matches for "get_seed".

Did you mean: set_seed
2012 Jan 27
2
The following code (using rgamma) hangs
...unsigned integer can go, it represents some kind of edge case. ################################################ #define MATHLIB_STANDALONE #include <Rmath.h> int main(void) { set_seed(0, 0); rgamma(1, 1); } ################################################ If I add the definitions of `get_seed` and `set_seed` from `src/nmath/standalone/sunif.c` to my code, then the hang disappears. ################################################ #define MATHLIB_STANDALONE #include <Rmath.h> /* A version of Marsaglia-MultiCarry */ static unsigned int I1=1234, I2=5678; void set_seed(unsigned in...
1997 Nov 24
0
R-alpha: random number generator -- S-plus's
...<< 'SHAR_EOF' > 'runif-tst.S' && ##SunOS4: print(dyn.load2("/u/maechler/C/C-for-S/Runif.o")) print(dyn.load("/u/maechler/C/C-for-S/Runif.o")) X.C("Init_seed", X Cval = as.integer(12345), X Tval = as.integer(987654321)) str(.C("Get_seed", Cval = integer(1), Tval = integer(1))) X rU_ numeric(10) for(i in 1:10) rU[i] <- unlist(.C("Runif", numeric(1))) rU str(.C("Get_seed", Cval = integer(1), Tval = integer(1))) X Set.seed <- function(Cval = 12345, Tval =987654321) { X ## Purpose: Initialize my impleme...
2003 Oct 08
1
R-1.8.0 is released
...e been modified to make the generic functions more self-contained (e.g., usable in apply-type operations) and potentially to speed dispatch. o The data editor is no longer limited to 65535 rows, and will be substantially faster for large numbers of columns. o Standalone Rmath now has a get_seed function as requested (PR#3160). o GC timing is not enabled until the first call to gc.time(); it can be disabled by calling gc.time(FALSE). This can speed up the garbage collector and reduce system calls on some platforms. o textConnection() now has a local argument for use with outp...
2003 Oct 08
1
R-1.8.0 is released
...e been modified to make the generic functions more self-contained (e.g., usable in apply-type operations) and potentially to speed dispatch. o The data editor is no longer limited to 65535 rows, and will be substantially faster for large numbers of columns. o Standalone Rmath now has a get_seed function as requested (PR#3160). o GC timing is not enabled until the first call to gc.time(); it can be disabled by calling gc.time(FALSE). This can speed up the garbage collector and reduce system calls on some platforms. o textConnection() now has a local argument for use with outp...