How to change XLabel, Title, Font size etc for bodeplot?

How to change XLabel, Title, Font size etc for bodeplot?

 Accepted Answer

'bodeplot' properties can be changed
1. By passing 'bodeoptions' to 'bodeplot' 
 
opts = bodeoptions('cstprefs');
opts.PhaseVisible = 'off';
opts.FreqUnits = 'Hz';
opts.Title.String = 'My Title';
opts.XLabel.String = 'My XLabel';
opts.Title.FontSize = 12;
h = bodeplot(tf(1,[1,1]),opts);
2. By using setoptions to modify the properties after 'bodeplot' is created.
h = bodeplot(tf(1,[1,1]));
options = getoptions(h);
options.PhaseVisible = 'off';
opts.FreqUnits = 'Hz';
options.Title.String = 'My Title';
options.XLabel.String = 'My XLabel';
options.Title.FontSize = 12;
setoptions(h,options);
For more details, please refer - http://www.mathworks.com/help/control/ref/bodeoptions.html

More Answers (0)

Categories

Find more on Graphics Object Properties in Help Center and File Exchange

Products

Release

R2016a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!