I have been using subplot in MATLAB for a long time, but I thought, "Maybe it's time to try migrating to tiledlayout..." so I explored how to use "tiledlayout" in a way that is familiar to "subplot" ...
The main() method returns the main figure at the uppermost level, and sets the active figure to it (as by default); any further commands will refer to the entire figure and to any of its subplots, if ...
This is a copy of code originally submitted to the Matlab File Exchange: https://www.mathworks.com/matlabcentral/fileexchange/47056-multipanel-figure-tools For people ...