function demo
clc;clear all;close all;
load result;

data_list_name = {'w1a','TDT2','20News','sector','E2006','MNIST','Gisette','CnnCaltech','Cifar','randn','randn','randn'};
mm_list = [2477 500 8000 6412 2000 60000 3000 3000 1000 500];
nn_list = [300 1000 1000 1000 1000 784 1000 1000 1000 1000];

time_list   = [10;20;30];
data_list   = [1:10];
r_list      = [20;50;100];
lambda_list = [1;300;1000];
 



for i_lambda_list = 1:length(lambda_list)
    for i_time_list = 1:length(time_list)
        fprintf(' \\hline\\hline  ');
        fprintf('\\multicolumn{10}{|c|}{\\centering $\\lambda$ = %.2f, time limit=%d} \\\\ \\hline ',lambda_list(i_lambda_list) ,time_list(i_time_list));fprintf(' \n');
        
        for i_r_list = 1:length(r_list)
            for i_data_list = 1:length(data_list)
 
                O = result{i_time_list,i_lambda_list,i_r_list,i_data_list};

                
%                 all_f = [Get3(O.f1);Get3(O.f2);Get3(O.f3);Get3(O.f4);Get3(O.f5);Get3(O.f6);Get3(O.f7)];
all_f = [(O.f1);(O.f2);(O.f3);(O.f4);(O.f5);(O.f6);(O.f7)];
all_f_scale = all_f - min(all_f);
                fprintf('%s-%d-%d & %.1e & %d ',data_list_name{i_data_list},mm_list(i_data_list), nn_list(i_data_list),min(all_f),r_list(i_r_list));

                for iii=1:length(all_f_scale)
                all_f(iii) = str2double(sprintf('%.2e',all_f_scale(iii)));
                end
                
                rank = my_rank(all_f);
                for iii=1:7
                    if(rank(iii)==0)
                        fprintf('& %.2e',all_f(iii));
                    elseif(rank(iii)==1)
                        fprintf('& \\cone{%.2e}',all_f(iii));
                    elseif(rank(iii)==2)
                        fprintf('& \\ctwo{%.2e}',all_f(iii));
                    elseif(rank(iii)==3)
                        fprintf('& \\cthree{%.2e}',all_f(iii));
                    end
                    
                 if(iii==6)
                     if(all_f(6)<all_f(1)-abs(all_f(1))*0.1 )
                     fprintf('\\cone{ (+)}');
                     end
                 end
                 if(iii==7)
                     if(all_f(7)<all_f(2)-abs(all_f(2))*0.1)
                     fprintf('\\cone{ (+)}');
                     end
                 end
                    
                end
                
                
                
                fprintf('\\\\\n');
                
                
            end
            fprintf(' \\hline ');
             fprintf(' \n');
        end
        
       
    end
      fprintf(' \n -------------------------------------- \n');
      fprintf(' \n -------------------------------------- \n');
      fprintf(' \n -------------------------------------- \n');
end


