I've got some experience using octave. However, matlab is acting very differently. I've got this simple script:
function y=test(x)
y=x*10;
end
a=test(10);
When I run it (that green 'play'-arrow in the GUI) it gives me the following error:
Error: File: TESTFILE.m Line: 5 Column: 1
This statement is not inside any function.
(It follows the END that terminates the definition of the function "bla".)
What's wrong? Can't I just run a scipt where I use my own functions next to code not within a function?