02.07.2013 Views

现代统计图形 - 科学网—博客

现代统计图形 - 科学网—博客

现代统计图形 - 科学网—博客

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

5.2 茎叶图 65<br />

1 > # lambda为10的泊松分布随机数<br />

2 > (x = rpois(50, 10))<br />

[1] 10 9 6 9 9 10 3 18 12 6 10 8 12 11 10 7 8 9 6 13<br />

[21] 9 11 6 12 6 6 11 11 13 16 14 8 7 7 6 8 10 14 6 11<br />

[41] 6 7 12 7 12 10 9 6 5 14<br />

1 > stem(x, scale = 2)<br />

The decimal point is at the |<br />

3 | 0<br />

4 |<br />

5 | 0<br />

6 | 0000000000<br />

7 | 00000<br />

8 | 0000<br />

9 | 000000<br />

10 | 000000<br />

11 | 00000<br />

12 | 00000<br />

13 | 00<br />

14 | 000<br />

15 |<br />

16 | 0<br />

17 |<br />

18 | 0<br />

图 5.4: λ = 10的泊松分布随机数茎叶图:可以看出数据密度在10附近最高,<br />

这与理论相符。注意这幅图可以完全还原到原始数据。

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!