Statistical programming, matrix languages, and more

What's the same function like R statement?

Reply
Contributor
Posts: 47

What's the same function like R statement?

R language stament, and how to do it by SAS IML?

b<-sample(1:9,size=3,replace=FALSE) , that means creating 1 set with 3 elements, every element is randomly selected from 1 to 9, and each element is different with the other two in the set(non-replacement sampling).

Thanks!

SAS Super FREQ
Posts: 3,232

Re: What's the same function like R statement?

If you have SAS/IML 12.1 (released with SAS 9.3M2), use the SAMPLE function.

Post a Question
Discussion Stats
  • 1 reply
  • 212 views
  • 3 likes
  • 2 in conversation