Thanks as always to Kit Baum, a new package ltop is now available for download from SSC. In Stata, use the ssc command to do this.
The ltop package is described as below on my website. It is part of my fleet of packages for making tables in a variety of formats from Stata datasets.
Best wishes
Roger
---------------------------------------------------------------------------------
package ltop from http://www.rogernewsonresources.org.uk/stata16
---------------------------------------------------------------------------------
TITLE
ltop: Divide a dataset into pages without splitting internal by-groups
DESCRIPTION/AUTHOR(S)
ltop ("lines to pages") creates a page-number variable, dividing the
dataset (or its by-groups) into pages, with a maximum number of lines per
page, optionally with internal by-groups which will not be split between
pages. ltop is designed for use when outputting datasets to multi-page
tables, using the SSC packages chardef, listtab, and docxtab. The user may
weight pages, in case different font sizes are to be used, or in case the
first line of each internal by-group is preceded by a gap line.
Author: Roger Newson
Distribution-Date: 24april2023
Stata-Version: 16
INSTALLATION FILES (click here to install)
ltop.ado
ltop.sthlp
---------------------------------------------------------------------------------
(click here to return to the previous screen)
The ltop package is described as below on my website. It is part of my fleet of packages for making tables in a variety of formats from Stata datasets.
Best wishes
Roger
---------------------------------------------------------------------------------
package ltop from http://www.rogernewsonresources.org.uk/stata16
---------------------------------------------------------------------------------
TITLE
ltop: Divide a dataset into pages without splitting internal by-groups
DESCRIPTION/AUTHOR(S)
ltop ("lines to pages") creates a page-number variable, dividing the
dataset (or its by-groups) into pages, with a maximum number of lines per
page, optionally with internal by-groups which will not be split between
pages. ltop is designed for use when outputting datasets to multi-page
tables, using the SSC packages chardef, listtab, and docxtab. The user may
weight pages, in case different font sizes are to be used, or in case the
first line of each internal by-group is preceded by a gap line.
Author: Roger Newson
Distribution-Date: 24april2023
Stata-Version: 16
INSTALLATION FILES (click here to install)
ltop.ado
ltop.sthlp
---------------------------------------------------------------------------------
(click here to return to the previous screen)