ST2 keep the content of the groups when you change layout as long as your new layout as the same or more groups.
If you switch from a 2 columns layout to a 3 lines layout and come back to 2 columns layout you will see that it works.
But if you switch from a 2 columns layout to a single columns layout discard the content of the second group.
I'm pretty sure it's possible to save the layout using a plugin:
1. Create your own set_layout command.
2. Use API method view.get_view_index() or window.views_in_group() to store the group index in the view.settings() for each view except views that have already a group index in the view.settings() greater than the actual number of group.
3. Call the standard set_layout command.
4. Use API method view.set_view_index() to put views back to the right group.