Don't use min and max as variable names, they are functions.
yyaxis is meant for use with two distinct plots, each of which has its own axis. Given that you are plotting nothing for the right axis I would assume you can just set its limits to whatever you want e.g. [0 9] and it will then work fine.
You only set the ticks, but you need to set the limits to be 0 to 9 otherwise the rest of your ticks are just missing off the top.