Format COMPACT not working
Show older comments
I was running a script and everything was in the compact format but I wanted to put format compact into the script so i could run the script anywhere and it would make sure it output answers in the compact format. As soon as I ran it with the new line "format compact" everything went to the loose format. I restarted matlab, opened a new file, restarted my computer, and deleted the format compact line. I changed my preferences to compact format but as soon as I run my script everything goes back to loose again. My script is literally like 30 lines and i only have one line in the entire thing that says format "......." it is the format compact line. No other lines say format anything. I cannot find an answer to this anywhere I am getting quite frustrated. I hope its just something dumb please help!
7 Comments
David Goodmanson
on 11 Jan 2020
Hi Joshua, what happens with format('compact') ?
Joshua Kreider
on 11 Jan 2020
John D'Errico
on 12 Jan 2020
Edited: John D'Errico
on 12 Jan 2020
Are you sure that your script does not call some other function of yours, that resets the format? We cannot see your script, so this is something we cannot know.
Joshua Kreider
on 12 Jan 2020
Joshua Kreider
on 12 Jan 2020
John D'Errico
on 12 Jan 2020
Yep. Been there, done that.
Joshua Kreider
on 12 Jan 2020
Answers (0)
Categories
Find more on Function Creation in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!