Learn R Programming

⚠️There's a newer version (0.3.0) of this package.Take me there.

pmxcode

The pmxcode Shiny app provides a user interface to create or modify pharmacometric models for various modeling and simulation software platforms.

Installation

You can install the development version of pmxcode like so:

# Install the lastest release from the CRAN
install.packages('pmxcode')

# Or install the development version from GitHub
# install.packages('devtools')
devtools::install_github('sbihorel/pmxcode')

Copy Link

Version

Install

install.packages('pmxcode')

Monthly Downloads

245

Version

0.2.0

License

MIT + file LICENSE

Maintainer

Sebastien Bihorel

Last Published

March 1st, 2025

Functions in pmxcode (0.2.0)

is_EDB

Determine if a square matrix is of type block, band or error
get_nonmem_code

Creation of NONMEM code
replace_pk_pred

Replace @PK and @PRED tags
new_model_server

New model module
replace_data

Replacement of @DATA tag
replace_des

Replace @DES tag
replace_input

Replacement of @INPUT tag
replace_error

Replace @ERROR tag
get_parms_code

Get NONMEM model parameter code lines as list
get_mrg_parms_code_minion

Get line of code for each parameter
get_mrgsolve_code

Creation of mrgsolve code
replace_mrg_plugin

Replacement of @PLUGIN tag
get_preamble_code

Get lines of preamble code for transit compartment absorption model and delayed dosing records
get_scaling_code

Get code lines for scaling and bioavailability
replace_mrg_capture

Replacement of @CAPTURE tag
replace_model

Replace @MODEL tag
get_theta_number

Get number of THETA parameters
replace_purpose

Replacement of @PURPOSE tag
replace_mrg_sigma

Replacement of @SIGMA tag
replace_problem

Replacement of @PROB1 and @PROB2 tags
replace_prior

Replacement of @PRIOR tag
replace_sigma

Replacement of @SIGMA tag
tenvars

Format variables by lines of 10.
replace_subroutine

Replacement of @SUBROUTINE tag
scale_value

Prepare initial estimate, min, and max for $THETA
pmxcode-package

pmxcode: Create Pharmacometric Models
replace_mrg_ode

Replacement of @ODE tag
replace_mrg_table

Replacement of @TABLE tag
replace_mrg_main_pred

Replace @MAIN or @PRED tags
hot_to_r_raw

Convert covariate handsontable data to R data.frame without factor
replace_path

Replacement of @PATH tag
replace_task

Replace @TASK tag
replace_theta

Replacement of @THETA tag
replace_nmext

Replacement of @NMEXT tag
replace_abbreviated

Replacement of @ABBREVIATED tag
replace_omega

Replacement of @OMEGA tag
replace_table

Replace @TABLE tag
replace_mrg_global

Replacement of @GLOBAL tag
replace_mrg_cmt

Replacement of @CMT tag
replace_tags

Replace $TAGs tag
run_app

Run the Shiny Application
replace_mrg_param

Replacement of @PARAM tag
resources

Load resource files
replace_mrg_omega

Replacement of @OMEGA tag
align_annotations

Auto indent mrgsolve code
get_correlation_table

Convert of covariance matrix into a 0/1 correlation map table
get_code

Creation of model code
get_derived_parms_code

Get lines of code for derived parameters
align_tags

Auto indent NONMEM code tags
notTruthy

Opposite of areTruthy
%>%

Pipe operator
file_exists

Determines if a file path exists
create_univariate_models

Generate univariate model code
areTruthy

Multi-argument version of isTruthy
check_covariate_table

Check covariate definition table
check_incomplete_covariate_table

Check if covariate definition table contains rows with incomplete data
get_mrg_parms_code

Get mrgsolve model parameter code lines as list
get_init_code

Get compartment intialization block
convert_reference_code

Convert reference code for univariate model creation
get_individual_parm_code

Get line of code for individual parameter value
get_ncmts

Get the number of PK and PD compartments
get_nonmem_blocks

Get NONMEM code blocks