how to rectify the error Index exceeds matrix dimensions.?
1 view (last 30 days)
Show older comments
prajwal prabhu on 27 Apr 2017
i am doing real time plotting of my sensor output in matlab. How to rectify the above error.This is my code.
axis([0 inf 0 3])
if((v(i)-v(i+1)==1)) tic else d(i)=toc; end end
When you enter the if-statement, v(i+1) does not yet exist because the array v is only constructed up to element v(i).
Find more on Specialized Power Systems in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!