nor - presumably the error message is
Undefined function or variable 'y'.
Error in *** (line 26)
plot(x,y)
The local variable y needs to be defined before you try to use it. What should it be? Why is x a scalar? Why do you have many local variables but do not use them in any of the variables that you plot? Please clarify and add comments to your code where necessary.
