From: aamir zeb on 25 Jun 2010 12:00 This is the part of main program Di(1,1) = fullDTWDist(Xt,Pattern(1)); Di(1,m) = fullDTWDist(Xt,Pattern(m)); This is the function called in the main program function fullDTWDist(X,Y) a=abs((X-Y)).^2; end This is the error ??? Error using ==> fullDTWDist Too many output arguments.
From: aamir zeb on 25 Jun 2010 12:04 "Andy " <theorigamist(a)gmail.com> wrote in message <i02ibo$os6$1(a)fred.mathworks.com>... > "aamir zeb" <addikted(a)gmail.com> wrote in message <i02hd8$l7f$1(a)fred.mathworks.com>... > > Hi there iam doing a project in matlab.ihave to call a function within a program when i run the whole programe...and when it reaches the function which is in the program it says "error using the abc function too many output arguments".kindly help me out. > > > > Regards > > AAMIR > > Could you provide some code for the abc function and your call to it from the main function? This is the part of main program Di(1,1) = fullDTWDist(Xt,Pattern(1)); Di(1,m) = fullDTWDist(Xt,Pattern(m)); This is the function that is called in the main program function fullDTWDist(X,Y) a=abs((X-Y)).^2; end This is the error it gives ??? Error using ==> fullDTWDist Too many output arguments.
From: us on 25 Jun 2010 12:12 "aamir zeb" <addikted(a)gmail.com> wrote in message <i02k25$hva$1(a)fred.mathworks.com>... > "Andy " <theorigamist(a)gmail.com> wrote in message <i02ibo$os6$1(a)fred.mathworks.com>... > > "aamir zeb" <addikted(a)gmail.com> wrote in message <i02hd8$l7f$1(a)fred.mathworks.com>... > > > Hi there iam doing a project in matlab.ihave to call a function within a program when i run the whole programe...and when it reaches the function which is in the program it says "error using the abc function too many output arguments".kindly help me out. > > > > > > Regards > > > AAMIR > > > > Could you provide some code for the abc function and your call to it from the main function? > > This is the part of main program > Di(1,1) = fullDTWDist(Xt,Pattern(1)); > Di(1,m) = fullDTWDist(Xt,Pattern(m)); > > This is the function that is called in the main program > function fullDTWDist(X,Y) > a=abs((X-Y)).^2; > end > > This is the error it gives > ??? Error using ==> fullDTWDist > Too many output arguments. again: well... of course did you use NARGOUT as you were told(!?)... CSSMers do NOT see any output arg in your function declaration(!)... function fullDTWDist(X,Y) end % at least, do something like this function a=fullDTWDist(X,Y) a=... end us
From: Jan Simon on 25 Jun 2010 12:19 Dear Aamir, > Di(1,1) = fullDTWDist(Xt,Pattern(1)); > Di(1,m) = fullDTWDist(Xt,Pattern(m)); > > This is the function that is called in the main program > function fullDTWDist(X,Y) > a=abs((X-Y)).^2; > end > > This is the error it gives > ??? Error using ==> fullDTWDist > Too many output arguments. This is the complete information we need. Fine. Your function fullDTWDist does not reply anything. So insert an output, here "a": function a = fullDTWDist(X,Y) a = abs((X-Y)).^2; end Good luck and welcome to Matlab, Jan
First
|
Prev
|
Pages: 1 2 Prev: draw an arc using just five points Next: Simple hack to get $600 to your home |