RPubs will retire in June 2027. Your existing documents will stay accessible through December 31, 2031
and Connect Cloud is the recommended home for new publishing. Read the blog post
gravatar

mbounthavong

Mark Bounthavong

Recently Published

MEPS Tutorial 8: Estimating slopes from a regression model using R
This tutorial reviews how to estimate the slopes from a survey-weighted regression model using the margins command.
Two-Part Model with Bootstrap using R
A guide on how to perform a two-part model with bootstrap using R.
One-sample z-test of proportions
A guide on how to perform one-sample z-test of proportions.
Literary Cafe Series: Patterns and costs associated with GLP1-RA among US adults with type 2 diabetes (Gettings data from MEPS)
This is the first part of a two-part tutorial on how to reproduce the findings from Wu and colleagues.
Evaluating the impact of policy using R - Part 2: Performing the interrupted time series analysis (ITSA)
The is the second in a two-part series of using publicly available data to replicate a published work in public health.
Evaluating the impact of policy using R - Part 1: Getting the data from CDC WONDER
The is the first in a two-part series of using publicly available data to replicate a published work in public health.
Loading data into R
A short exercise on how to load data into R in the *.csv and *.xlsx file formats
R - Tips and Tricks (Guide) - Part 2
This a helpful guide on using R
Ratio of Risk Ratios in R
A short tutorial on how to estimate the ratio of risk ratios in R.
Transform data from wide to long format in R
This is a tutorial on how to transform data from the wide to long format in R
Generate data using the simstudy package in R - Part 1
This is part 1 of a short guide on how to generate data using the simstudy package in R.
Estimating medication adherence (MPR and PDC) in R using the AdhereR package - Part 1
This is the first part of a series of tutorials on how to estimate medication adherence in R.
Propensity Score Matching in R
This is a tutorial on how to perform propensity score matching using R.
Stata - marginsplot & mplotoffset commands for plotting average marginal effects
A tutorial that revieweed some basic features of the marginsplot and mplotoffset commands and provide some practical examples of customization.
Prepost analysis with continuous data using R - Part 1
This is a tutorial on how to perform simple prepost analysis using R.
Linear spline (Piecewise) model in Stata
This is a tutorial on how to construct linear spline (also known as piecewise) models using Stata.
Tips and Tricks (Guide) - R and RStudio
This is a collection of tips and tricks for R and RStudio.
Distributions in cost-effectiveness analysis
This is a tutorial on how to generate common distributions for performing a probabilistic sensitivity analysis for a cost-effectiveness analysis.
Mediation analysis using R
A tutorial on how to perform mediation analysis using R.
Staggered Difference-in-Differences using R
This is the Callaway & Sant'Anna staggered difference-in-differences framework using R
R - Loading data from Google drive
A tutorial on how to load data from Google drive into an R environment
Presentations with R Markdown - Part 3: Font colors
This is part 3 on how to construct a presentation using R Markdown. This part will focus on changing font colors.
Surival Analysis - Immortal Time Bias in Stata
A survival analysis tutorial addressing immortal time bias using a time-varying predictor in Stata
Constructing a Markov Model using Excel: A tutorial
A tutorial on how to construct a Markov model using Excel.
MEPS Tutorial 7 - Helpful notes
This is a tutorial on MEPS and my notes that I found helpful.
MEPS Tutorial 6 - Interrupted Time Series Analysis (ITSA) with R: A Short Tutorial
A tutorial on how to perform simple trend analysis with R using linear regression models.
MEPS Tutorial 5 - Simple Trend Analysis with Linear Models
A tutorial on how to perform simple trend analysis with R using linear regression models.
MEPS Tutorial 4 - Using condition-event link (CLNK) file
This is a tutorial on how to apply the MEPS link file to merge the conditions and events files in R
Interrupted time series analysis (ITSA) with Stata
A tutorial on constructing ITSA models using Stata
Exact matching using R - MatchIt package
A tutorial on performing exact matching using the MatchIt package in R.
Building a book using the bookdown package in R - Part 2: Chapters and References
This is the second in a series of how to create an e-book using bookdown
Building a book using the bookdown package in R - Part 1: Introduction
Tutorial on how to build a book using the R bookdown package.
Building HTML Presentation using R Markdown - Part 2: Add new slides
This is the second part of a series on how to create presentation using R Markdown.
Tweedie distribution for GLM gamma model
This is a tutorial on how to construct a Tweedie GLM Gamma model using an identity link for costs data. I used the MEPS data from 2020 for this tutorial.
Two-part model - Application with cost data using R
This R tutorial review how to use the two-part model for cost data.
Building HTML Presentation using R Markdown - Part 1: Introduction
This is the first tutorial on how to construct an HTML presentation using R Markdown.
Interpreting Regression Models
Short explanation of how to interpret regression coefficients
MEPS Tutorial 3 - Applying weights
This is a tutorial on how to apply survey weights with MEPS data in R
MEPS Tutorial 2 - Merging Data into R
This is a tutorial on how to merge MEPS data files with R.
MEPS Tutorial 1 - Loading data into R
This is a tutorial on how to load MEPS data into R.
Stata tutorial - Add 95% Confidence Intervals to Two-way Line Plot
This is a Stata tutorial on how to add 95% CI to a two-way line plot.
R Plotly - Bar Charts
A tutorial on using plotly in an R Markdown project.
Sample Size estimation using odds ratio in a case-control study
A short tutorial on using the epiR package to estimate sample size for a case-control trial based on the odds ratio.
Survival analysis in R
Tutorial on using R to perform survival analysis
Linear Regression models using R
This is a tutorial on how to use R to build and validate linear regression models
Confounding and Interaction
R tutorial on confounding and interaction using epitools and epiR package
Sample size estimation and Power analysis in R
This is a tutorial on how perform some basic sample size estimates and power analysis using the R "pwr" package.
Logistic Regression in R - Part 2 (Goodness of fit)
This is the second part of how to perform logistic regression in R. I focus on using goodness of fit tests to determine if the logistic regression model we specified is a good fit of the observed data.
Logistic Regression in R
This is a tutorial on how to construct logistic regression models in R.
Visualizing Linear Regression Models
A brief R tutorial on how to visualize the output of linear regression models.
Forest plots in R
Tutorial on how to create forest plots in R
Decision Tree Model in R Tutorial
This decision tree model uses R to generate the incremental cost, incremental outcomes, and incremental cost-effectiveness ratio. It also include R code for performing a one-way sensitivity analysis and constructing a tornado diagram.
Using inverse probability of treatment weights & Marginal structural models to handle time-varying covariates
Simple example illustrating the benefits of applying inverse probability of treatment weights fitted to a marginal structural model.
bayesAB exercise
This is a short exercise created by BC Mullins for the bayesAB package.
Bayesian meta-analsis using JAGS
This is a tutorial to perform meta-analyses using Bayesian methods with JAGS in the R environment.