Hi all,
I have a brief question.
Aside from manually editing the following graph in adobe illustrator or the likes, is there a way to have these error bars offset so they appear over only the orange bars. Moreover, is there a way that I can make the error bars two tailed.
Here is my code:
function GraphDataAbs( Title, Legend, YLabel, YValues_mean, YValues_std, Behaviours ) %Add back in YValues for scatter
h=figure; xvalues= (1:numel(Behaviours)); hold on; er = errorbar(xvalues, YValues_mean(1,:), YValues_std); hold on; bar(xvalues, YValues_mean, 'BarWidth', 1); hold on; er.Color = [0 0 0]; er.LineStyle = 'none'; set(gca,'XTick',1:numel(Behaviours),'XTickLabel',Behaviours); ax = gca; ax.XColor = 'k' ax.YColor = 'k' set(gca, 'FontName', 'Tahoma') xtickangle(45); ylim([0, ((max(max(YValues_mean))*1.6))]); legend(Legend); title(Title); ylabel (YLabel); filename = Title saveas(h,filename,'jpg') saveas(h,filename, 'epsc')
Best Answer