Displaying 7 results from an estimated 7 matches similar to: "setseed() works well"
2011 Mar 26
1
set.seed
Dear list,
It looks like set.seed does not work for me (see code below). I am running
Debian squeeze. Is this an issue with the distribution or with my understanding
of the function? I'm pretty sure, but not certain, it used to work that way on
windows
> runif(5)
[1] 0.6516557 0.5677378 0.1135090 0.5959253 0.3580500
> runif(5)
[1] 0.42880942 0.05190332 0.26417767 0.39879073
2008 Jan 02
1
setting the seed in standalone code using Rlib
Hi,
Is the below -- setSeed -- an okay way to set the seed in standalone
applications making use of Rlib? It seems to work as expected. Is
there a better way to do it? (I'm also looking at do_setseed but am
unsure what to supply as op. findFun("set.seed", R_GlobalEnv)?) Thanks
much.
--
David Faden, dfaden at iastate.edu
AIM: pitulx
--
#include <assert.h>
#include
1997 Nov 24
0
R-alpha: random number generator -- S-plus's
--Multipart_Mon_Nov_24_14:51:09_1997-1
Content-Type: text/plain; charset=US-ASCII
>>>>> "PaulG" == Paul Gilbert <pgilbert@bank-banque-canada.ca> writes:
MM> The code is basically in V&R 1 and 2; V&R2 on p.167. I have it as a
MM> C function that I used to dyn.load into S-plus in order
MM> to prove that S-plus was using it.
2011 Nov 03
2
Take variables in data.frame and create list of matrices
Hi,
I have this sample data below and would like to create a list of matricies.
setseed(1254)
id <- c(1,1,1,1 ,2,2,2)
o <- as.factor(c(1:4, 1, 3, 4))
r <- rep(.5, 7)
v <- rnorm(7)
s <- rnorm(7)
dat <-data.frame(id, o, r, v, s)
dat
#> dat
# id o r v s
# 1 1 0.5 0.7024631 2.0813672
# 1 2 0.5 -0.5541955 0.1095156
# 1 3 0.5 -1.0418167 0.4164930
# 1
1999 Jan 01
0
RE: timeslab
On 01-Jan-99 Prof Brian Ripley wrote:
> -rw-rw---- 1 root sysadmin 188267 Jan 1 06:20
> timeslab-1.0-1.tar.gz
> -rw-rw-r-- 1 root sysadmin 180290 Jan 1 02:02
> timeslab-1.0.tar.gz
>
> So which is which, what's the difference? ....
Sorry if this wasn't self evident:
timeslab-1.0.tar.gz == timeslab-1.0-0.tar.gz
and thus
2005 Dec 21
2
Random numbers
Hi All.
I have R code whose functionality is being replicated within a C+
program. The outputs are to be compared to validate the conversion
somewhat - however (as is always the case) I have stuffed my code with
random number calls.
Random uniform numbers in C+ are being produced using the (Boost)
mersenne-twister generators (mt11213b & mt19937) - which is the default
type of generator
1997 Sep 15
0
R-alpha: set.seed(.) [was 'compatibility']
>>>>> Thomas Lumley writes:
>> Two compatibility issues found while trying to convert a simulation
>> from S to R.
>> 1. set.seed() We don't have this function. According to Venables &
>> Ripley it just picks a seed from a list of 1000 possibilities. How about
>>
>> "set.seed" <-function (i)