SyntaxFix
Write A Post
Hire A Developer
Questions
Also it'd work to just specify ifelse() twice:
ifelse()
plot(pos,cn, col= ifelse(cn >= 3, "red", ifelse(cn <= 1,"blue", "black")), ylim = c(0, 10))