フィルターのクリア

100 Random numbers given t-distribution with mu = x% std = y% and df = 100?

1 回表示 (過去 30 日間)
Steven Niggebrugge
Steven Niggebrugge 2017 年 8 月 17 日
コメント済み: Star Strider 2017 年 8 月 18 日
How can i create a 100 x 2 array with random numbers, given the following distribution: -mu = 2% -sigma = 3% -df = 100
thanks very much!

回答 (1 件)

Star Strider
Star Strider 2017 年 8 月 17 日
The trnd (link) function does not allow you to specify a mean and standard deviation as arguments to the function. However, with 100 degrees-of-freedom, the t-distribution is essentially the same as the normal distribution. Use the normrnd (link) function instead.
  3 件のコメント
Torsten
Torsten 2017 年 8 月 18 日
Given df, mu and sigma are given. You can't prescribe them.
Best wishes
Torsten.
Star Strider
Star Strider 2017 年 8 月 18 日
@Torsten — Thank you.

サインインしてコメントする。

Community Treasure Hunt

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

Start Hunting!

Translated by