How to calculate the number of points lying above and below the regression line in the scatter chart?
data = read.csv("info.csv") par(pty = "s") plot(data$col1, data$col2, xlab = "xaxis", ylab = "yaxis", xlim = c(0, 1), cex.lab = 1.5, cex.axis = 1.5, ylim = c(0, 1), col.lab = "red", col = "blue", pch = 19) abline(a = -1.21, b = 2.21)
source share