%%

%%% GRAPHICAL RESULTS

close all;
clear all;
clc


%%% For voxels with 0.1

in=dlmread('incoming');
rg=dlmread('region_growing');
eu=dlmread('euclidean_cluster');

time_step=0.4;

in=transp(in);
rg=transp(rg);
eu=transp(eu);

in=in*time_step;
rg=rg*time_step;
eu=eu*time_step;

time=1:time_step:108;

plot(time,in,'k','LineWidth',3);
hold on;
plot(time,rg,'r','LineWidth',3);
plot(time,eu,'b','LineWidth',3);

size=25;

h_leg=legend('Nuvem de pontos com os obst\''{a}culos (entrada)','Regi\~{a}o crescente','Segmentac\~{a}o euclidiana');
set(h_leg,'interpreter','latex');
x_l_handle=xlabel('Tempo (s)','interpreter','latex','FontSize',size,'FontWeight','b');
y_l_handle=ylabel('Frequ\^{e}ncia (Hz)','interpreter','latex','FontSize',size,'FontWeight','b');

set(gca,'FontSize',size,'FontWeight','b');

%%  Média de pontos

point_size=dlmread('point_size');

M_points=mean(point_size)

M_euclidean=mean(eu)

M_region=mean(rg)

M_input=mean(in)