image.png

    1. leg=legend({'Original','3 years','1 year + 2 months',...
    2. '1 year (with Double Period)', '1 year'},...
    3. 'Location','northeast','Orientation','horizontal');
    4. set(leg,'FontName','Times New Roman','FontSize',20,'FontWeight','normal')

    image.png
    image.png

    leg=legend({'Original','3 years','1 year + 2 months',...
             '1 year (with Double Period)', '1 year'},...
             'Location','north','Orientation','horizontal');   
        legend('boxoff'); % 不显示图例框
        set(leg,'FontName','Times New Roman','FontSize',20,'FontWeight','normal')
    

    image.png
    间距有点近,怎么解决呢,图例里面文字部分加空格呀
    额,不行,好像是自动忽略掉了
    还是末尾加上 空格 和 | 吧

    leg=legend({'Original    |','3 years    |','1 year + 2 months    |',...
             '1 year (with Double Period)    |', '1 year'},...
             'Location','north','Orientation','horizontal');   
    legend('boxoff'); % 不显示图例框
    set(leg,'FontName','Times New Roman','FontSize',20,'FontWeight','normal')
    

    image.png
    空格+ ‘·’挺舒服的
    image.png