yarrr icon indicating copy to clipboard operation
yarrr copied to clipboard

how can i combine all the plots in one layout ???

Open ALOMASSI opened this issue 1 year ago • 0 comments

i have tried this script but it doesn't work :

library(yarrr)

cf <- pirateplot(formula = Cf (m) ~ VerSts, data = massi, main = "Circonférence (m)", theme= 1, bean.f.o = .6, # Bean fill point.o = .3, # Points inf.f.o = .7, # Inference fill inf.b.o = .8, # Inference border avg.line.o = 1, # Average line bar.f.o = .5, # Bar inf.f.col = "white", # Inf fill col inf.b.col = "black", # Inf border col avg.line.col = "black", # avg line col bar.f.col = gray(.8), # bar filling color point.pch = 21, point.bg = "white", point.col = "black", point.cex = .7) Ht <- pirateplot(formula = HT ~ VerSts, data = massi, main = "Hauteur totale de l’arbre (m)", theme= 1, bean.f.o = .6, # Bean fill point.o = .3, # Points inf.f.o = .7, # Inference fill inf.b.o = .8, # Inference border avg.line.o = 1, # Average line bar.f.o = .5, # Bar inf.f.col = "white", # Inf fill col inf.b.col = "black", # Inf border col avg.line.col = "black", # avg line col bar.f.col = gray(.8), # bar filling color point.pch = 21, point.bg = "white", point.col = "black", point.cex = .7) LH <- pirateplot(formula = Long. H ~ VerSts, data = massi, main = "Longueur du houppier (m)", theme= 1, bean.f.o = .6, # Bean fill point.o = .3, # Points inf.f.o = .7, # Inference fill inf.b.o = .8, # Inference border avg.line.o = 1, # Average line bar.f.o = .5, # Bar inf.f.col = "white", # Inf fill col inf.b.col = "black", # Inf border col avg.line.col = "black", # avg line col bar.f.col = gray(.8), # bar filling color point.pch = 21, point.bg = "white", point.col = "black", point.cex = .7) D.h <- pirateplot(formula = D.houppier ~ VerSts, data = massi, main = "Diamètre du houppier (m)", theme= 1, bean.f.o = .6, # Bean fill point.o = .3, # Points inf.f.o = .7, # Inference fill inf.b.o = .8, # Inference border avg.line.o = 1, # Average line bar.f.o = .5, # Bar inf.f.col = "white", # Inf fill col inf.b.col = "black", # Inf border col avg.line.col = "black", # avg line col bar.f.col = gray(.8), # bar filling color point.pch = 21, point.bg = "white", point.col = "black", point.cex = .7) library(patchwork) cf + Ht + LH + D.h + plot_layout(ncol=2)

please help me

ALOMASSI avatar Jun 01 '23 00:06 ALOMASSI