I use lattice package to draw the picture using the below csv file.
I used the below code and got the expected picture.
library(lattice)
data_1 <- read.table("./stackoverflow.csv", header=T, sep=",")
data <- na.omit(data_1)
xyplot(a ~ b | c, data = data, panel = function(x, y){
panel.xyplot(x, y)
}
)
Moreover, I used the below code and got the next expected picture.
library(lattice)
data_1 <- read.table("./stackoverflow.csv", header=T, sep=",")
data <- na.omit(data_1)
xyplot(a ~ b | c, data = data, panel = function(x, y){
panel.xyplot(x, y)
panel.lmline(x, y)
}
)
I want not to use panel.lmline for the data leading to the error message, and I want the below picture. The picture is the composite (damy) image.
How should I do to use the conditional branches for R lattice package.
R 4.0.5, lattice 0.20-38, MacOS 10.14.5 were used.