For this code:
40: y1_x=y_data(1)41: y1=round(y1_x)42: y2_x=y_data(2)43: y2=y2_x-y1_x+y1
I get this output(and warning):
y1_x = 57.3517y1 = 57y2_x = 83.3517y2 = 83Warning: Integer operands are required for colon operator when used asindex > In sonar_prob at 43 In robot_diferential at 60 In Painel>RunSimulation at 259 In Painel>pushbuttonReactive_Callback at 154 In gui_mainfcn at 96 In Painel at 16 In @(hObject,eventdata)Painel('pushbuttonReactive_Callback',hObject,eventdata,guidata(hObject))
I couldn't find any reason for this warning…what can it mean?
Best Answer