library(scatterplot3d) a<- read.csv("./temp-salt-visc.csv", header=T) alm <- lm(a$visc~a$temp+a$nacl) png(filename="temp-salt-viscosity.png",width = 640, height = 640, units="px",pointsize=12,bg="white") s3d <- scatterplot3d(a$temp,a$nacl,a$visc) s3d$plane(alm,lty.box = "solid") dev.off() summary(alm)