March 14, 2011
Matlab : Create Random Data in Range
We can create random data in Matlab with command :
- rand (Uniformly distributed pseudorandom numbers)
- randn (Normally distributed random numbers)
- unifrnd (Continuous uniform random numbers)
- random (Random numbers)
If we want to create random data in range, we can use unifrnd function. Example :
unifrnd (1 , 10 , [5,1])
This command will create random data in range 1 to 10 with output row=5 and column=1.
2 Comments
apaan tuh?
Your article helped me a lot, is there any more related content? Thanks!