je souhaite faire un barplot mais avec 2 barres a chaque label des x
j ai 2 variables lin_E_pt et lin-E_gd
Code : Tout sélectionner
> lin_E_pt
0 1 2 3 4 5 6
0.33333333 0.22222222 0.11111111 0.26666667 0.02222222 0.02222222 0.00000000
8
0.02222222
> lin_E_gd
0 1 2 3 4 5 6 8
0.50 0.44 0.00 0.02 0.00 0.02 0.02 0.00
j ai essayé de mettre un at =
j ai particionner l axe des x en 17 points et mettre la variable 1 aux points 1,3,5,.... et la variable 2 aux points 2, 4,6 ....
mais cela ne marche pas
quelqu'un aurai une idée
Code : Tout sélectionner
g1<-lin_E_pt
g2 <- lin_E_gd
step1 <- c(seq( 1, 16, by=2))
step2 <- c(seq( 2, 17, by=2))
windows()
barplot(g1, at= strep1,col="black", xaxt="n")
barplot(g2,add=T, col="grey",at= step2)
axis(side=1,at=seq(1,17, by=1))
merci d avance pour votre aide