Simple extension of basic layout function from R.