02.07.2013 Views

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

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

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

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

附录 D 本书R包<br />

为了配合本书的写作,作者特意编写了一个R包名为MSG(Modern<br />

Statistical Graphics的缩写),该包目前可从作者主页下载,在本书完成后<br />

也会发布到CRAN供读者下载。这里简要介绍一下它包含的函数和数据。<br />

D.1 函数说明<br />

usage() 显示一个函数的用法。该函数可以根据指定的函数名称获取函数的<br />

参数列表,并将其以整齐的方式打印出来,如:<br />

1 > # plot函数的用法<br />

2 > usage(plot)<br />

plot(x, y, ...)<br />

1 > # plot的默认用法,即plot.default<br />

2 > usage(plot, "default")<br />

plot(x, y = NULL, type = "p", xlim = NULL,<br />

ylim = NULL, log = "", main = NULL, sub = NULL,<br />

xlab = NULL, ylab = NULL, ann = par("ann"), axes = TRUE,<br />

frame.plot = axes, panel.first = NULL, panel.last = NULL,<br />

asp = NA, ...)<br />

1 > # plot在画经验分布函数的时候的用法,即plot.ecdf<br />

2 > usage(plot, "ecdf")<br />

plot(x, ..., ylab = "Fn(x)", verticals = FALSE,<br />

col.01line = "gray70", pch = 19)<br />

1 > # usage自身的用法<br />

2 > usage(usage)<br />

usage(FUN, class = NULL, w = 0.77)<br />

179

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

Saved successfully!

Ooh no, something went wrong!