width = 3; height = 3; alw = 1.75; fsz = 24; lw = 2.5; msz = 8; task_syn_8 = [0.109749]; task_full = [0.104282]; task_syn_3 = [0.156843]; act_syn_8 = [0.0277134]; act_full = [0.0656282]; act_syn_3 = [0.0269723]; total_syn_8 = [0.189391]; total_full = [0.186361]; total_syn_3 = [0.322083]; y = [ task_syn_3, act_syn_3, total_syn_3 - task_syn_3 - act_syn_3; task_syn_8, act_syn_8, total_syn_8 - task_syn_8- act_syn_8; task_full, act_full, total_full - task_full - act_full; ]; bar(y,'stacked'); legend('Task', 'Effort', 'Other', 'Location', 'NorthEast'); set(gca, 'xticklabels', {'3 Syn', '8 Syn', 'Full'}, 'FontSize', fsz); ylabel('Cost Function Value'); set(gca, 'FontSize', fsz, 'LineWidth', 2.5); legend boxoff; box off;