%  figure ('Name','Vykresleni polohovych dat','NumberTitle','off')
% scatter (lt_surface_data(:,3)',lt_surface_data(:,2)',50,lt_surface_data(:,1),'x')
% hold on
% axis equal
% xlabel ({'East','[°]'})
% ylabel ({'North','[°]'})
% grid minor
% hold on

[m,n] = size(gt_output);
ls_count_pos = [0 0 0 0];
ls_count_hdg = [0 0 0 0 0 0];
i_hdg_output = 1;
for i=1:m;
    if gt_output(i,6) ~= 99999;
        if abs(gt_output(i,6))<30;
            if abs(gt_output(i,6))<10;
                if abs(gt_output(i,6))<3;
                    ls_count_pos(1,1) = ls_count_pos(1,1) + 1;
                else;
                    ls_count_pos(1,2) = ls_count_pos(1,2) + 1;
                end;
            else;
                ls_count_pos(1,3) = ls_count_pos(1,3) + 1;
            end;
        else;
            ls_count_pos(1,4) = ls_count_pos(1,4) + 1;
        end;
    end;
    
      if gt_output(i,7) ~= 999;
        gt_hdg_output(i_hdg_output,1) = gt_output(i,1);
        gt_hdg_output(i_hdg_output,2) = gt_output(i,7);
        i_hdg_output = i_hdg_output + 1;
          if gt_output(i,7)<30;
            if gt_output(i,7)<10;
                if gt_output(i,7)<4.5;
                    if gt_output(i,7)<1;
                        if gt_output(i,7)<0.35;
                            ls_count_hdg(1,1) = ls_count_hdg(1,1) + 1;
                        else;
                            ls_count_hdg(1,2) = ls_count_hdg(1,2) + 1;
                        end;
                    else;                        
                    ls_count_hdg(1,3) = ls_count_hdg(1,3) + 1;
                    end;
                else;
                    ls_count_hdg(1,4) = ls_count_hdg(1,4) + 1;
                end;
            else;
                ls_count_hdg(1,5) = ls_count_hdg(1,5) + 1;
            end;
        else;
            ls_count_hdg(1,6) = ls_count_hdg(1,6) + 1;
        end;
    end;
end;

figure ('Name','Cetnost polohovych chyb','NumberTitle','off')
bar(ls_count_pos)
hold on

figure ('Name','Cetnost chyb HDG','NumberTitle','off')
bar(ls_count_hdg)
hold on



    
                        