In short: yes, this is an insane assignment.
Stata, being proprietary software, has not released all the details of its core components, such as a random number generator. However, documentation is available (link for Stata 14), most appropriate:
runiform() is the basis for all other random number functions, since all other random numbers, numerical functions transform uniform (0, 1) random numbers into a given distribution.
runiform() implements the 64-bit version of Mersenne Twister (MT64) and "keeps it simple stupid" of 32-bit (KISS32) algorithms for creating uniform (0, 1) random numbers. runiform() uses the MT64 default algorithm .
runiform() uses the KISS32 algorithm only when the user version is less than 14 , or when the random number generator is set to kiss32 ...
Recall also from ?Random in R, which is for Mersenne twister:
"A seed is a 624-dimensional set of 32-bit integers plus the current position in that set.
Stata internally controls the 624-dimensional set, which is almost impossible to guess.
I suggest you export these random numbers from Stata and read them into a vector / matrix / etc. in R using
library(haven) mydata <- read_dta("mydata.dta")
Chris conlan
source share