在qualityTools中出现pcr问题

时间:2016-10-08 05:06:43

标签: r plot

在qualityTools中使用pcr函数绘制过程功能时,我遇到了一个问题

D=matrix(c(0,30,15,30,0,0,0,0,0,0,0,0,0,0,8,15,10,0,0,0,0,0,0,0,20,30,15,0,0,0,0,0,0,0,15,60,12,0,0,0,0,0,0,0,0,0,0,60,15,0,0,0,0,0,0,0,0,10,15,0,0,0,0,0,0,0,0,20,20,0,0,0,0,0,0,0,0,0,0,20,0,0,0,0,0,0,0,0,0,15,0,0,0,0,0,0,0,0,0,0),nrow=10,byrow=T)  

library(igraph)

g2 <- graph.adjacency(D, mode = "directed", weighted = TRUE)

plot(g2, edge.label = round(E(g2)$weight,2))   

直方图背景用数字覆盖!不知道出了什么问题。有人可以看看吗?

谢谢!

The histogram background is covered with numbers!

1 个答案:

答案 0 :(得分:1)

您可以通过使用参数pcr调用xlab = ""来解决此问题,即

pcr(x, "weibull", lsl = 100, usl = 117, xlab = "")

解释。pcr的检查表明它正在使用hist以下列方式呼叫do.call

do.call(hist, c(list(x[, 1], freq = FALSE, xlim = xlim, ylim = ylim, main = ""), parList))        

此构造为输入创建一个名称,用于连接向量的所有值。然后,此名称显示为x轴标签。您可以通过调用,例如

来复制此行为
do.call(hist, c(list(rnorm(3), main = "")))

解决方案是设置xlab = ""