Linear Mixed Effects models based on Stochastic Differential Equations in R
Soren Klim, Stig Mortensen and Henrik Madsen
Technical University of Denmark
Objectives: In the master thesis  and article  a framework for handling Non-Linear Mixed Effects models based on Stochastic Differential Equations (SDEs) were presented.
The framework was built in Matlab which is a commercial product. In order to make the framework wider available an R-Package was developed.
Methods: The R-package PSM  contains methods for simulation, estimation and smoothing of LME-models based on SDEs. The models are restricted to additive error but using a log-transform this limitation can be extended to proportional error. The package for now restricted to linear models.
The estimation procedure is maximum likelihood based with a FOCE approximation. The intra-individual models are handled through the linear Kalman filter in order to incorporate the stochastic differential equations. The use of SDEs enables the separation of observation noise and system noise in the data which is a powerful modelling property as explained in .
The models can include dosing and multidimensional observations. Furthermore the time consuming parts of the code has been moved to Fortran in order to make computational time smaller.
Results: A package able of handling LME-models based on SDEs is now available in R. This will enable an easier way to get started with stochastic differential equations.
As all R-Packages, PSM is a free and easy to install in R. The capabilities of working with model simulation, estimation and smoothing in R makes it possible to load and handle data, work with the modelling and plot the results in the same program.
Conclusion: The R-package PSM is a option for all users to get started with SDEs without having to buy programs or learn how to implement the Kalman filter by hand.
 S. Klim and S. Mortensen. DTU-IMM, Master Project 2006
 S. Mortensen et al. Journal of PK/PD. 2007 Oct; 34(5):623-42
 S. Klim and S. Mortensen - http://www.imm.dtu.dk/psm
 R. Overgaard et al. Journal of PK/PD. 2005 Feb;32(1):85-107