ordistep(vegan)
ordistep()所属R语言包:vegan
Choose a Model by Permutation Tests in Constrained Ordination
选择置换测试模型的约束排序
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Automatic stepwise model building for constrained ordination methods (cca, rda, capscale). The function ordistep is modelled after step and can do forward, backward and stepwise model selection using permutation tests. Function ordiR2step performs forward model choice solely on adjusted R2 and P-value, for ordination objects created by rda or capscale.
自动逐步建立模型约束的协调方法(cca,rda,capscale“)。的功能ordistep是仿照step,可以做向前,向后和逐步的模型选择排列测试。功能ordiR2step执行模式的选择完全的调整R2和P-值,为配合创建的对象rda或capscale。
用法----------Usage----------
ordistep(object, scope, direction = c("both", "backward", "forward"),
Pin = 0.05, Pout = 0.1, pstep = 100, perm.max = 1000, steps = 50,
trace = TRUE, ...)
ordiR2step(object, scope, direction = c("both", "forward"),
Pin = 0.05, pstep = 100, perm.max = 1000,
trace = TRUE, ...)
参数----------Arguments----------
参数:object
In ordistep, an ordination object inheriting from cca or rda. In ordiR2step, the object must inherit from rda, that is, it must have been computed using rda or capscale.
在ordistep,协调对象继承自cca或rda。在ordiR2step,该对象必须继承自rda,也就是说,它必须是计算机使用rda或capscale。
参数:scope
Defines the range of models examined in the stepwise search. This should be either a single formula, or a list containing components upper and lower, both formulae. See step for details. In ordiR2step, this defines the upper scope; it can also be an ordination object from with the model is extracted.
定义模型检验的范围在逐步的搜索。这应该是一个公式或一个列表,其中包含upper和lower,这两个公式的组件。见step的详细信息。在ordiR2step,这定义的上部的范围内,它也可以是一个协调与模型中提取的对象从。
参数:direction
The mode of stepwise search, can be one of "both", "backward", or "forward", with a default of "both". If the scope argument is missing, the default for direction is "backward".
该模式的逐步搜索,可以是一个"both","backward"或"forward",用默认的"both"。如果scope参数丢失,默认为direction是"backward"。
参数:Pin, Pout
Limits of permutation P-values for adding (Pin) a term to the model, or dropping (Pout) from the model. Term is added if P <= Pin, and removed if P > Pout.
置换P值增加(限制Pin),任期到模型中,或删除(Pout)从模型。术语添加P <=Pin,并删除如果P >Pout的。
参数:pstep
Number of permutations in one step. See add1.cca.
号码的排列在一个步骤。见add1.cca。
参数:perm.max
Maximum number of permutation in anova.cca.
在anova.cca的最大数量的排列。
参数:steps
Maximum number of iteration steps of dropping and adding terms.
最大迭代步数的下降和增加的条款。
参数:trace
If positive, information is printed during the model building. Larger values may give more information.
如果是正数,信息印在模型的建立。较大的值可能提供更多的信息。
参数:...
Any additional arguments to add1.cca and drop1.cca.
任何额外的参数add1.cca和drop1.cca。
Details
详细信息----------Details----------
The basic functions for model choice in constrained ordination are add1.cca and drop1.cca. With these functions, ordination models can be chosen with standard R function step which bases the term choice on AIC. AIC-like statistics for ordination are provided by functions deviance.cca and extractAIC.cca (with similar functions for rda). Actually, constrained ordination methods do not have AIC, and therefore the step may not be trusted. This function provides an alternative using permutation P-values.
在受约束的协调模式的选择的基本功能是add1.cca和drop1.cca。有了这些功能,协调模型可以选择与标准R的功能step碱基AIC的术语选择。 AIC-统计协调所提供的功能deviance.cca和extractAIC.cca(具有类似功能的rda)。事实上,制约协调的方法并没有AIC,因此step可能不信任。此功能提供了另一种排列P值。
Function ordistep defines the model, scope of models considered, and direction of the procedure similarly as step. The function alternates with drop and add steps and stops when the model was not changed during one step. The - and + signs in the summary table indicate which stage is performed. The number of permutations is selected adaptively with respect to the defined decision limit. It is often sensible to have Pout > Pin in stepwise models to avoid cyclic adds and drops of single terms.
函数ordistep定义模型,scope的考虑的模型,并direction的过程,同样作为step。功能交替drop和add步骤,并停止在一个步骤时,该模型没有改变。 -和+汇总表中的迹象表明哪一个阶段进行。自适应地选择的排列数相对于定义的决定限制。它往往是明智的做法有Pout>Pin的逐步模型,以避免循环增加和下降的一个术语。
Function ordiR2step builds model so that it maximizes adjusted R2 (function RsquareAdj) at every step, and stopping when the adjusted R2 starts to decrease, or the adjusted R2 of the scope is exceeded, or the selected permutation P-value is exceeded (Blanchet et al. 2008). The direction has choices "forward" and "both", but it is very excepctional that a term is dropped with the adjusted R2 criterion. Function uses adjusted R2 as the criterion, and it cannot be used if the criterion cannot be calculated. Therefore it is unavailable for cca.
功能ordiR2step建立模型,以便最大限度地调整R2(函数RsquareAdj)步步为营,和停止时的调整R2开始下降,或者调整<X >的R2超标,或选择排列scope值超标(布兰切特等,2008)。 P选择direction和"forward",但它是一个术语的下降非常excepctional,调整后的"both"标准。函数使用调整R2作为判据,它不能被用于如果不能计算标准。因此,它是不可用R2。
Functions ordistep (based on P values) and ordiR2step (based on adjusted R2 and hence on eigenvalues) can select variables in different order.
功能ordistep(根据P值)和ordiR2step(根据调整后的R2,因此对特征值),可以选择不同的顺序中的变量。
值----------Value----------
Functions return the selected model with one additional component, anova, which contains brief information of steps taken. You can suppress voluminous output during model building by setting trace = FALSE, and find the summary of model history in the anova item.
函数返回所选择的模型与一个附加组件,anova,其中包含简短信息所采取的步骤。模型的建立过程中,可以抑制大量输出,通过设置trace = FALSE在anova项目模型历史的总结。
(作者)----------Author(s)----------
Jari Oksanen
参考文献----------References----------
of explanatory variables. Ecology 89, 2623–2632.
参见----------See Also----------
The function handles constrained ordination methods cca, rda and capscale. The underlying functions are add1.cca and drop1.cca, and the function is modelled after standard step (which also can be used directly but uses AIC for model choice, see extractAIC.cca). Function ordiR2step builds upon RsquareAdj.
该函数处理约束的协调方法cca,rda和capscale。基本功能是add1.cca和drop1.cca,功能是仿照标准的step(也可以直接使用,但使用AIC模式的选择,请参阅extractAIC.cca)。函数ordiR2step建立在RsquareAdj。
实例----------Examples----------
## See add1.cca for another example[#请参阅add1.cca的另一个例子]
### Dune data[##沙丘数据的]
data(dune)
data(dune.env)
mod0 <- rda(dune ~ 1, dune.env) # Model with intercept only[模型的拦截只]
mod1 <- rda(dune ~ ., dune.env) # Model with all explanatory variables[所有解释变量的模型]
## With scope present, the default direction is "both"[#使用范围目前,默认的方向是“既”]
ordistep(mod0, scope = formula(mod1), perm.max = 200)
## Example without scope. Default direction is "backward"[#示例没有范围。默认方向是“落后”。]
ordistep(mod1, perm.max = 200)
## Example of ordistep, forward[#示例ordistep,向前]
## Not run: [#不运行:]
ordistep(mod0, scope = formula(mod1), direction="forward", perm.max = 200)
## End(Not run)[#(不执行)]
### Mite data[##螨数据的]
data(mite)
data(mite.env)
mite.hel = decostand(mite, "hel")
mod0 <- rda(mite.hel ~ 1, mite.env) # Model with intercept only[模型的拦截只]
mod1 <- rda(mite.hel ~ ., mite.env) # Model with all explanatory variables[所有解释变量的模型]
## Example of ordiR2step with default direction = "both"[#的ordiR2step示例使用默认方向=“既”]
## (This never goes "backward" but evaluates included terms.)[#(这永远不会“落后”,但评估包括的条款。)]
step.res <- ordiR2step(mod0, mod1, perm.max = 200)
step.res$anova # Summary table[汇总表]
## Example of ordiR2step with direction = "forward"[#的ordiR2step例与方向“前进”]
## Not run: [#不运行:]
step.res <- ordiR2step(mod0, scope = formula(mod1), direction="forward")
step.res$anova # Summary table[汇总表]
## End(Not run)[#(不执行)]
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|