Displaying 1 result from an estimated 1 matches for "wzorzec2".
Did you mean:
wzorzec1
2010 Aug 16
1
xyplot - I can't find colors in my picture
Hi,
Anybody can tell me why I don't have colors in my picture?
library(lattice)
my.pch<-c(17,16,15,18,20,9,10,12)
my.fill<-c('yellow','black','green','red','blue','cyan','magenta','pink')
wzorzec1<- c(1,3,2,4,6,4,2,3)
wzorzec2<- c(5,3,6,6,2,3,4,1)
a<-factor(wzorzec1)
b<-factor(wzorzec2)
n1<-c(11,22,33,22,5,22,33,24)
n2<-c(4,3,5,7,8,4,3,2)
xyplot(n1~n2,
panel=function(x,y, ...,subscripts) {
pch <- my.pch [a[subscripts]]
fill<- my.fill [b[subscripts]]
panel.xyplot(x,y,pch=pch,...