Imposing interval on normrnd procedure.

Hello
I'm running the following line of code, but would like to impose an interval on the drawings from 0 to 10. d1=normrnd(3.35, 2.02,n1,1);
All ideas would be helpful,
Regards, Lena

回答 (1 件)

bym
bym 2011 年 12 月 11 日

0 投票

imposing an interval on the result means it is no longer a normal distribution. With that caveat:
d1(d1<0 | d1>10)=[];

カテゴリ

ヘルプ センター および File ExchangeAerospace Blockset についてさらに検索

質問済み:

2011 年 12 月 11 日

Community Treasure Hunt

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

Start Hunting!

Translated by