Borrar filtros
Borrar filtros

functions does not appear

1 visualización (últimos 30 días)
Vasiliki Vasilopoulou
Vasiliki Vasilopoulou el 13 de Feb. de 2023
Editada: Matt J el 13 de Feb. de 2023
Hello everybody,
I try to learn how Matlab can be used. I study matlab books and I have problem with functions. When I want to create a Function, the message appearing is " Function definition are not supported in this context. Functions can only be created as local or nested functions in code files".
What's exactly is the problem?
Thank you

Respuestas (1)

Matt J
Matt J el 13 de Feb. de 2023
Editada: Matt J el 13 de Feb. de 2023
You cannot create non-anonymous functions in the command window. You need to compose them in a .m file. It is recommendable that you use the Matlab Editor for that,
>> edit myFunction.m
See also,

Categorías

Más información sobre Get Started with MATLAB en Help Center y File Exchange.

Productos

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by