As in Matlab Notebook use functions?

As in Matlab use functions? For example, I wrote a function mymin, then created a .doc file and all placed in the same folder. Here is what is displayed when calling the function in MS Word:
vec=[1 2 3 4 4];
a=mymin(vec)
??? Undefined function 'mymin' for input arguments of type 'double'.

답변 (2개)

Roberto
Roberto 2014년 5월 13일
편집: Roberto 2014년 5월 13일

0 개 추천

From what i know, functions must be named * .m not * .doc and shouldn't be saved in msWord format, but plain text format, for example in wondows notepad or in the built-in editor!!
cheng chen
cheng chen 2017년 3월 14일

0 개 추천

your matlab "current directory" must include the function "mymin" what you difined.

카테고리

도움말 센터File Exchange에서 Installing Products에 대해 자세히 알아보기

질문:

2014년 5월 13일

답변:

2017년 3월 14일

Community Treasure Hunt

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

Start Hunting!

Translated by