我正在使用素食主义者进行 DCA 任命。我想显示我的分组站点,但是当我使用 ordispider 时,组的标签相互隐藏。我怎样才能调整他们的位置?有可能以某种方式使用 orditkplot 吗?
问问题
2682 次
2 回答
1
不,不可能orditkplot()
with ordispider()
,它根本不知道如何处理这样的任意绘图功能。
您没有说明为什么要用于ordispider()
在 DCA 排序中显示您的分组站点?您不需要将它们加入某个质心或类似的位置,只是为了表明组成员身份。相反,您可以使用绘图符号来区分组,例如
require("vegan")
data(dune)
data(dune.env)
mod <- decorana(dune)
plot(mod, display = "sites", type = "n")
## colour & shape according to Management
col <- c("red","orange","forestgreen","navy")
pch <- 1:4
## add the points
with(dune.env,
points(mod, display = "sites", col = col[Management],
pch = pch[Management]))
## add a legend
legend("topright",
legend = with(dune.env, levels(Management)),
col = col, pch = pch, title = "Management",
bty = "n")
或者,我想您可以在没有标签的情况下进行绘图并稍后添加它们,也许locator()
用于识别放置标签的绘图的清晰区域,例如:
plot(mod, display = "sites", type = "p")
with(dune.env, ordispider(mod, groups = Management, col = "red"))
## select 4 locations
coords <- locator(with(dune.env, length(levels(Management))))
## now you have to click on the plot where you want the labels
## automagically finishes after you click the 4th label in this case
## draw labels
text(coords, labels = with(dune.env, levels(Management)))
于 2013-05-16T22:34:21.680 回答
0
您是否尝试过vegan
小插图中的以下内容?
2.1. Cluttered plots
Ordination plots are often congested: there is a large number of sites and species, and it may be impossible to display all clearly. In particular, two or more species may have identical scores and are plotted over each other. Vegan does not have (yet?) automatic tools for clean plotting in these cases, but here some methods you can try:
- Zoom into graph setting axis limits xlim and ylim. You must typically set both, because
vegan will maintain equal aspect ratio of axes.
- Use points and add labell only some points with identify command.
- Use select argument in ordination text and points functions to only show the specied
items.
- Use ordilabel function that uses opaque background to the text: some text labels will
be covered, but the uppermost are readable.
- Use automatic orditorp function that uses text only if this can be done without overwriting
previous labels, but points in other cases.
于 2013-05-16T11:44:50.053 回答