rvSEL(SEL)
rvSEL()所属R语言包:SEL
Simulate from the expert's distribution
从专家的分布模拟
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Simulate random variables from an SEL object.
模拟随机变量的从SEL对象。
用法----------Usage----------
rvSEL(n, object, nPoints = 1000)
参数----------Arguments----------
参数:n
Number of simulated values.
模拟值的数目。
参数:object
An SEL object.
SEL对象。
参数:nPoints
Number of evaluations for the brute force inversion of the expert cdf.
号码的专家民防部队的暴力反转的评价。
Details
详细信息----------Details----------
The inverse of the distribution function is formed by evaluating the distribution function at nPoints points and interchanging the role of dependent and independent variable when building an function interpolating the data (using splinefun with "monoH.FC" option). Note that there are also direct ways of inverting a B-spline function, which however turned out to be less efficient for our purposes.
通过评估npoints的点分布函数和转乘的依赖和独立的变量,当建立一个函数内插的数据(使用splinefun与"monoH.FC"选项)的作用而形成的分布函数的逆。注意的反转B样条函数,但我们的目的是低效率的,也有直接的方法。
值----------Value----------
A numeric vector containing pseudo-random variates from the expert's density.
一个数字矢量包含伪随机变数专家的密度。
(作者)----------Author(s)----------
Bjoern Bornkamp
参考文献----------References----------
Bornkamp, B. and Ickstadt, K. (2009). A Note on B-Splines for Semiparametric Elicitation. The American Statistician, 63, 373–377
参见----------See Also----------
SEL, splinefun
SEL,splinefun
实例----------Examples----------
## bimodal example [#双峰的例子]
x2 <- c(0.1, 0.2, 0.5, 0.8, 0.9)
y2 <- c(0.2, 0.4, 0.45, 0.85, 0.99)
fit1 <- SEL(x2, y2, Delta=0.05, d = 4, inknts = x2)
fit2 <- SEL(x2, y2, Delta=0.05, d = 15, N = 0)
comparePlot(fit1, fit2, superpose = TRUE)
## sample from SEL object[#样品SEL对象]
xxx <- rvSEL(50000, fit1)
hist(xxx, breaks=100, freq=FALSE)
curve(predict(fit1, newdata=x), add=TRUE)
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|