A Prototype Software Framework for Transferable Computational Health Economic Models and Its Early Application in Youth Mental Health

To help readyforwhatsnext meet all six TRU criteria, we developed a prototype software framework called ready4 [14].

3.1 Framework User Requirements

The framework user requirements (FURs) for ready4 evolved over 6 years (2018–2024) as we encountered new implementation issues for readyforwhatsnext that we needed to solve. Currently, these requirements are:

FUR 1: A reusable template for CHEM modules that can be: (i) run as independent models; (ii) safely combined, sharing inputs and outputs with each other without unintended interference; and (iii) selectively replaced, updated or extended.

FUR 2: A programming syntax that promotes simplicity and consistency in how algorithms associated with CHEM modules are: (i) labelled and (ii) used in health economic analysis programs.

FUR 3: Module authoring tools that integrate with online software development services to help author CHEM modules that are: (i) created using the template module; (ii) written in a consistent house style; (iii) always at least minimally documented; (iv) licensed for reuse; (v) bundled as R libraries with authorship, funding source, version number and digital object identifier (DOI) metadata; and (vi) quality assured with publicly available testing artefacts.

FUR 4: Data management tools that integrate with online data repository services to streamline: (i) the ingesting and labelling of confidential and non-confidential data and (ii) the sharing of non-confidential data.

FUR 5: Replication and reporting tools that: help (i) author analysis and reporting template programs for rendering HTML, Adobe PDF and Microsoft Word outputs; (ii) retrieve version-specific analysis and reporting template programs from online code repositories; and (iii) supply analysis and reporting template programs with study specific data (e.g. authorship details, input data and analysis results) to render custom reports.

FUR 6: Search tools to retrieve web-based information on a CHEM project’s: (i) model modules and tutorials; (ii) datasets and data collections; and (iii) replication and reporting template programs.

FUR 7: Documentation tools that integrate with open source website development and hosting infrastructure to help: (i) develop a CHEM project documentation website that consolidates content from the websites of individual CHEM module libraries, datasets and programs and (ii) partially automate the updating of website resources such as tutorials and itemised lists of code and data releases.

3.2 Framework Implementation

We implemented ready4 as R [15] code libraries that integrate with a number of online services. The framework is documented by a project website.

3.2.1 R Libraries

R libraries typically depend on other R libraries. As the number of dependencies of an R library grows, so does the fragility of that library (e.g. the library may cease to work as intended due to changes in one of its dependency libraries). To reduce the fragility of our framework we implemented it as multiple R libraries rather than one R library. We authored six novel R libraries to implement the ready4 framework, all of which have distinct purposes and dependencies (Table 1).

To meet FUR 1, the ready4 [16] foundation library defines a template CHEM module using R’s S4 class system. Benefits of using the S4 class system include automated verification that data supplied to modules adhere to pre-specified criteria and support for object-oriented programming. Two notable features of object-oriented programming are encapsulation [17] and inheritance [17]. Encapsulation allows a CHEM module to bundle model data and algorithms in a protected environment, which is useful for helping ensure that CHEM modules continue to work as intended when combined. Inheritance allows new CHEM modules to inherit some or all of the properties of a parent module. Inheritance is useful when modifying CHEM modules, for example, to account for: (i) interaction effects when CHEMs are combined or (ii) distinctive features of new decision contexts to which they are being transferred. The ready4 template CHEM module can be used to create other CHEM modules that inherit a common set of properties. One of these inherited properties is a novel syntax of 15 core commands [18] that enable CHEM module algorithms to be consistently named and described (meeting FUR 2). The ready4 library also contains tools for retrieving web-based information on CHEM modules, datasets and analysis programs (meeting FUR 6) and tools for developing and maintaining a CHEM project’s documentation website (meeting FUR 7).

Three module authoring libraries are designed to meet FUR 3. The ready4fun [19] library contains tools for writing functions in a consistent house style and automatically generating basic documentation for each function. The ready4class [20] library contains tools to help streamline and standardise the authoring of novel, documented CHEM modules from the template CHEM module. The ready4pack [21] library provides tools for disseminating themed bundles of CHEM modules as R libraries that are: documented (with a website and PDF manuals); licensed (using the copyleft GNU GPL-3 [22] by default); easily citable (citation information can be retrieved within an R session or from hosting repositories); and quality assured (each update triggers the running of any tests created by module library authors, with test results publicly documented).

The ready4use [23] library for managing CHEM data contains tools for supplying CHEM modules with input data ingested from local (i.e. a user’s computer) or remote (online repositories) locations, labelling CHEM module datasets and exporting CHEM module data to online repositories (meeting FUR 4). The ready4show [24] library for authoring reproducible analysis programs and reporting subroutines (FUR5) contains tools to help write executables that apply CHEM modules to compatible datasets for the purpose of undertaking reproducible health economic analyses. The library supports the creation of analysis programs that are self-documenting (code is integrated with plain English explanations of what it does) and subroutines that can be used as templates that trigger the creation of explanatory documents (e.g. a scientific manuscript).

Table 1 Software framework R libraries3.2.2 Online Services

Framework libraries are designed to be used in conjunction with a number of online services. The module authoring libraries use the GitHub [25] service’s tools for: software development, testing, version control and distribution; hosting of documentation websites; and transparent record keeping of collaborator contributions. Continuous integration [26] tools provided by GitHub are used to trigger systematic retesting of module libraries with every edit. Tests can be unit tests (verifying the correct output when small, isolated sections of code are run independently) and acceptance tests (verifying the correct output from multiple code components are run together to meet core user-requirements [27]). The module authoring libraries use the codecov [28] service to measure and share information about code coverage [29]—the proportion of code that has been explicitly tested. The open science repository service Zenodo [30] is used by the module authoring libraries to provide persistent storage, uniquely identified with a digital object identifier (DOI), of each code release. The ready4use library uses the Dataverse [31] data repository service for persistent, uniquely identifiable and versioned storage of model input and output data. For the management of frequently updated datasets that do not require persistent storage, all framework libraries use GitHub.

3.2.3 Documentation Website

A project documentation website (https://www.ready4-dev.com) provides guidance to model developers on how to use and contribute improvements to the ready4 software framework. Prior versions of the documentation website are archived and publicly accessible. The documentation website was developed using the Hugo framework [32], Docsy theme [33] and Algolia DocSearch [34] and is hosted using the Netlify [35] service. We linked our Netlify account to our GitHub organisation so that the project website automatically updates whenever its (publicly available) source code is edited.

留言 (0)

沒有登入
gif