R 更改lattice coplot条带字体

R 更改lattice coplot条带字体,r,plot,lattice,R,Plot,Lattice,我正在尝试更改biom和days的条形文本大小。我看到其他帖子建议使用strip.custom()更改字体大小。但它不起作用,我不知道如何修复它。我得到这个警告: 警告消息: 在plot.xy(xy.coords(x,y)中,type=type,…: “条带”不是图形参数 growth是默认的graphics包中的一个函数。是lattice包中的函数。我认为这是你使用这个解决方案的主要问题。 growth <- c(15, 12, 7, 9, 4, 5, 9, 9) days <

我正在尝试更改
biom
days
的条形文本大小。我看到其他帖子建议使用
strip.custom()
更改字体大小。但它不起作用,我不知道如何修复它。我得到这个警告:

警告消息:
在plot.xy(xy.coords(x,y)中,type=type,…:
“条带”不是图形参数

growth是默认的
graphics
包中的一个函数。是
lattice
包中的函数。我认为这是你使用这个解决方案的主要问题。
growth <- c(15, 12, 7, 9, 4, 5, 9, 9)
days   <- c(1, 2, 1, 2, 1, 2, 1, 2)
biom   <- c(0.5, 1, 0.5, 1, 0.5, 1, 0.5, 1)
herb   <- c(20, 22, 35, 30, 35, 34, 28, 26)
dfgrowth <- data.frame(growth, days, biom, herb)

library(lattice)
coplot(growth ~ herb | as.factor(biom) * as.factor(days), data=dfgrowth, 
       columns=4, overlap=0, pch=21, bar.bg=c(num=gray(1), fac=gray(0.95)),
       strip=strip.custom(par.strip.text=list(cex=2)))