From: James Tursa on
"Doris wang" <doris_wy_us(a)yahoo.com> wrote in message <hmjrek$ic4$1(a)fred.mathworks.com>...
>
> I check in the open MATLAB window that the directory is "myfolder". Would that means the engine is really in "myfolder"?

Yes. Is that where your m-file function is? If so, try running it directly from the engine window and see what happens.

James Tursa
From: Doris wang on
I tried what you said, the error message in the MATLAB window is

"undefined function or method "myfuntion" for input argument "double".

Why am I&#12288;getting this error?

Doris


"James Tursa" <aclassyguy_with_a_k_not_a_c(a)hotmail.com> wrote in message <hmk1ds$lff$1(a)fred.mathworks.com>...
> "Doris wang" <doris_wy_us(a)yahoo.com> wrote in message <hmjrek$ic4$1(a)fred.mathworks.com>...
> >
> > I check in the open MATLAB window that the directory is "myfolder". Would that means the engine is really in "myfolder"?
>
> Yes. Is that where your m-file function is? If so, try running it directly from the engine window and see what happens.
>
> James Tursa
From: James Tursa on
"Doris wang" <doris_wy_us(a)yahoo.com> wrote in message <hmk2v6$48s$1(a)fred.mathworks.com>...
> I tried what you said, the error message in the MATLAB window is
>
> "undefined function or method "myfuntion" for input argument "double".
>
> Why am I&#12288;getting this error?

The file myfuntion.m (typo? your spelling) is *not* in the current engine directory nor is it on the MATLAB path. Try myfunction (with the c).

James Tursa
From: Doris wang on
Sorry, that is a typo here in the forum. The actual name of my function is not "myfunction" and I am sure I typed it right in the command window of MATLAB. So the error message is still
undefined function or method "myfunction" for the input argument of type "double".


Doris

"James Tursa" <aclassyguy_with_a_k_not_a_c(a)hotmail.com> wrote in message <hmk83k$76f$1(a)fred.mathworks.com>...
> "Doris wang" <doris_wy_us(a)yahoo.com> wrote in message <hmk2v6$48s$1(a)fred.mathworks.com>...
> > I tried what you said, the error message in the MATLAB window is
> >
> > "undefined function or method "myfuntion" for input argument "double".
> >
> > Why am I&#12288;getting this error?
>
> The file myfuntion.m (typo? your spelling) is *not* in the current engine directory nor is it on the MATLAB path. Try myfunction (with the c).
>
> James Tursa
From: James Tursa on
"Doris wang" <doris_wy_us(a)yahoo.com> wrote in message <hmkaat$r4u$1(a)fred.mathworks.com>...
> Sorry, that is a typo here in the forum. The actual name of my function is not "myfunction" and I am sure I typed it right in the command window of MATLAB. So the error message is still
> undefined function or method "myfunction" for the input argument of type "double".

So the answer is the same. The file myfunction.m is *not* in the current engine directory nor is it on the MATLAB path. Double check where it is.

James Tursa