How can I center the text printed by display('the text')?
Eg, like the text you get when entering matlab.
A function to get the width of the current terminal will do to (I’ll figure it out from there).
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
with a fairly new version of matlab you can do:
Otherwise, you’ll have to use a mex file:
see this link http://www.mathworks.com/matlabcentral/newsreader/view_thread/25315