How to obtain a random number selection from a list

1 view
Skip to first unread message

Luis Cubillos

Dec 15, 2021, 4:48:09 PM12/15/21

Dear ADMB users,

I am trying a code to obtain an integer from a list in ADMB, similar to this in R:

output <- sample(size=1, x = c(1,2), prob= c(0.8,0.2))

Is there any option in C++ or ADMB?

Luis Cubillos
Reply all
Reply to author
0 new messages