如何使用R删除coplot中的“​​Given”

时间:2011-05-02 13:26:18

标签: r graphics statistics

有没有人知道如何删除coplot中的“​​Given”签名?我知道如何使用coplot(...,show.given = FALSE),但这会删除的不仅仅是“Given”。我希望你们明白我在说什么,因为我的英语不太好!

再见

1 个答案:

答案 0 :(得分:7)

以下是来自?coplot的可重复示例:

## Tonga Trench Earthquakes
coplot(lat ~ long | depth, data = quakes)

因此,问题是如何阻止R在图中的木瓦部分的标签中写下“给定:”,或者就此而言改变整个标签。

如果我们查看?coplot的帮助,我们会看到x轴和y轴标签(分别为xlabylab)的参数取两个值,并且它是将"Given : "添加到条件变量的每个标签中的第二个元素的默认行为。

因此,解决方案是提供您自己的标签:

coplot(lat ~ long | depth, data = quakes, xlab = c("Longitude", "Depth"),
       ylab = "Latitude")

给出:

coplot example