Why I get error during analysis ?

3 Ansichten (letzte 30 Tage)
VIJAY KUMAR
VIJAY KUMAR am 8 Mär. 2016
Bearbeitet: Walter Roberson am 9 Apr. 2016
Hai,
I tried to run this matlab program (AnalyseDataLaas), But it is showing a error like this in the command window
>> AnalyseDataLaas
Output argument "turns" (and maybe others) not assigned during call to
"D:\Vijay\RodTracker-v1.0.2\PlotTrajectories.m>PlotTrajectories".
Error in AnalyseDataLaas (line 144)
[saveStruct, stretches, rod, turns, drift, velocity] =
PlotTrajectories(saveStruct,closeAllWindows,errorbars,0);
So I checked the line 144 and it is written like this
[saveStruct, stretches, rod, turns, drift, velocity] = PlotTrajectories(saveStruct,closeAllWindows,errorbars,0);
please help anybody to solve it

Antworten (2)

Ced
Ced am 8 Mär. 2016
It means that you defined "turns" as being an output argument in "PlotTrajectories", but you never assigned any value to it (it does not exist). Check your "PlotTrajectories" function and make sure "turns" exists when you exit the function.

Matthew Eicholtz
Matthew Eicholtz am 8 Mär. 2016
This is difficult to answer without knowing what the functions AnalyseDataLaas and PlotTrajectories look like.
However, the error that you are receiving simply means that some of the expected outputs from PlotTrajectories (e.g. 'turns'), are not being assigned. Look at the function PlotTrajectories and make sure that somewhere in the code it is assigning something to 'turns' (and all the other outputs as well).
Here is another (albeit trivial) example where you would encounter this error:
function y = fcn(x)
z = x^2; %I meant to set y to x^2 but I accidentally typed z instead
end
If you type the follow in the Command Window:
y = fcn(4);
You will receive the following error:
Output argument "y" (and maybe others) not assigned during call to "fcn".
Because nowhere in the code do I set y equal to something. Hope this helps.

Kategorien

Mehr zu Image Processing Toolbox finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by