How to make a random number generator with a normal distribution in matlab

4 ビュー (過去 30 日間)
Lukasz Subramanian
Lukasz Subramanian 2018 年 1 月 25 日
編集済み: Sean de Wolski 2018 年 1 月 25 日
Hey How to make a random number generator. I want numbers to be from some x-y range, e.g. 1-5. so that I can choose how many of these results should be N = k np. N = 150 and so that I can choose the distribution of these results, eg normal distribution, oblique. I need to generate results with different distributions. So, for example, 160 results with a normal, oblique distribution, etc. so that I could then throw them into my model. How to do it ?

回答 (1 件)

Sean de Wolski
Sean de Wolski 2018 年 1 月 25 日
編集済み: Sean de Wolski 2018 年 1 月 25 日
Use makedist to make a distribution object with the appropriate parameters and then call random on it"

カテゴリ

Help Center および File ExchangeRandom Number Generation についてさらに検索

製品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by