Kyle T. Baron, Pharm.D., Ph.D., Devin Pastoor, Ph.D., Anna Nevison, M.S., Katherine Kay, Ph.D., Marc R. Gastonguay, Ph.D.
Metrum Research Group
Introduction/Objectives: Scientists have a need for standardized, programmatically-generated tables summarizing outputs of modeling and simulation analyses.
The objective of this work was to develop an R package to format typical pharmacometric output into LaTeX tables using an iterative open-source software development life cycle (SDLC) methodology.
Methods: Pmtables is a freely available open-source R package, available on GitHub [1], for the summarization of data sets in publication-quality tables. The package was developed using a transparent, open-source SDLC process that incorporated robust planning, iterative development, validation, and release.
In the planning of pmtables, the development team investigated the need for standardized tabular outputs in pharmacometric analyses. This exploratory phase included reviewing reports to identify standard table types and common structural features across tables that typically appear in reports. From this process, user stories were defined to represent desired features, and the user stories were then prioritized in a product roadmap.
Software development followed an iterative process of coding, testing, and feedback. Coding was performed incrementally, using the specifications and user stories prioritized in the planning process. Tests were written to closely reflect the real-world scenarios of the user stories and consisted of a series of unit tests that captured the expected behavior across pieces of code. Unit tests were executed locally by the developer as well as on a continuous integration server each time commits were made to the git repository. Feedback from the testing informed further coding, and this stage was considered complete after successful review of code, test results, and acceptance criteria.
Results: pmtables was first released in August, 2020 (v0.1.0) and there have been a total of 6 maintenance and development releases over the life of the package, including 133 issues submitted by end-users and closed by the development team. For the most-recent release (v0.3.3), there were 606 expectations evaluated within 206 unit tests (or user stories). The code coverage was 92%.
pmtables currently provides three data summary tables: continuous data summary, categorical data summary, and a data inventory table (summarizing numbers of individuals and observations in a data set). All tables can be rendered in a tabular environment or a longtable environment (the table can span multiple pages). Users have the option to (1) add footnotes (2) denote groups of rows (or panels) in the table (3) denote groups of columns with column “spanners” (4) add notes below the table and (4) add different types of styling to the table. Tables can be annotated with the source R code file name and the output file name and automatically saved to .tex file in ascii format. Table preview tools are also provided to help users quickly visualize their tables in a test TeX document mimicking the report environment where the table will eventually be rendered. To help users learn the table syntax, an annotated examples document was created and hosted on github [2].
Conclusions: The development and validation of the pmtables package illustrates the feasibility and utility of a modern software development life cycle for open source pharmacometrics software.
References:
[1] https://github.com/metrumresearchgroup/pmtables
[2] https://github.com/metrumresearchgroup/pmt-book
Reference: PAGE 29 (2021) Abstr 9874 [www.page-meeting.org/?abstract=9874]
Poster: Methodology - Other topics