Reputation: 67
I wanted to plot this:
plot( 0, 0, type = "n",xlim =c(-3, 3), ylim =c(-5, 5), xlab = "x", ylab = "y" )
However, on the graph, it shows the y axes range is not c(-5, 5) but c(-4,4).
Upvotes: 2
Views: 1749
Reputation: 887088
It is based on the tick labels, we can do
plot( 0, 0, type = "n",xlim =c(-3, 3), ylim =c(-4, 4),
xlab = "x", ylab = "y" , yaxt = 'n')
axis(2, -4:4)
Upvotes: 4