Thanks a lot, Rick! Following your solution above, what're your suggestions to generate random numbers from a predefined distribution rather than "Normal"? For example, what about if we want to have numbers from a Binomial? Can we still write "N*pdf( "binomial", t, Mean, StdDev);", or there're other alternative functions available in SAS? Appreciate your comments.