Monday, March 27, 2017

[solved]Subscript indices must either be real positive integers or logicals

I got this error when using the function size()

Because I defined a variable named "size" that overwrote this function




Matlab had better name the function GetSize() since "size" is a common name for customer variables


So the solution is: copy out the variable content (size2=size;)  and right click to delete your variable named "size"

No comments:

Post a Comment