Skip to main content

Advertisement

Log in

Zero-Inflated Regime-Switching Stochastic Differential Equation Models for Highly Unbalanced Multivariate, Multi-Subject Time-Series Data

  • Published:
Psychometrika Aims and scope Submit manuscript

Abstract

In the study of human dynamics, the behavior under study is often operationalized by tallying the frequencies and intensities of a collection of lower-order processes. For instance, the higher-order construct of negative affect may be indicated by the occurrence of crying, frowning, and other verbal and nonverbal expressions of distress, fear, anger, and other negative feelings. However, because of idiosyncratic differences in how negative affect is expressed, some of the lower-order processes may be characterized by sparse occurrences in some individuals. To aid the recovery of the true dynamics of a system in cases where there may be an inflation of such “zero responses,” we propose adding a regime (unobserved phase) of “non-occurrence” to a bivariate Ornstein–Uhlenbeck (OU) model to account for the high instances of non-occurrence in some individuals while simultaneously allowing for multivariate dynamic representation of the processes of interest under nonzero responses. The transition between the occurrence (i.e., active) and non-occurrence (i.e., inactive) regimes is represented using a novel latent Markovian transition model with dependencies on latent variables and person-specific covariates to account for inter-individual heterogeneity of the processes. Bayesian estimation and inference are based on Markov chain Monte Carlo algorithms implemented using the JAGS software. We demonstrate the utility of the proposed zero-inflated regime-switching OU model to a study of young children’s self-regulation at 36 and 48 months.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5

Similar content being viewed by others

References

  • Ait-Sahalia, Y. (2008). Closed-form likelihood expansions for multivariate diffusions. The Annals of Statistics, 36(2), 906–937.

    Article  Google Scholar 

  • Arminger, G. (1986). Linear stochastic differential equation models for panel data with unobserved variables. In N. Tuma (Ed.), Sociological methodology 1986 (pp. 187–212). San Francisco: Jossey-Bass.

    Google Scholar 

  • Bai, Y., & Wu, L. (2018). Analytic value function for optimal regime-switching pairs trading rules. Quantitative Finance, 18(4), 637–654. https://doi.org/10.1080/14697688.2017.1336281.

    Article  Google Scholar 

  • Baumeister, R. F., & Vohs, K. D. (2007). Self-regulation, ego depletion, and motivation. Social and Personality Psychology Compass, 1, 115–128. https://doi.org/10.1111/j.1751-9004.2007.00001.x.

    Article  Google Scholar 

  • Beaulieu, J. M., Jhwueng, D. C., Boettiger, C., & O’Meara, B. C. (2012). Modeling stabilizing selection: Expanding the Ornstein–Uhlenbeck model of adaptive evolution. Evolution, 66(8), 2369–2383. https://doi.org/10.1111/j.1558-5646.2012.01619.x.

    Article  PubMed  Google Scholar 

  • Beskos, A., Papaspiliopoulos, O., & Roberts, G. (2009). Monte Carlo maximum likelihood estimation for discretely observed diffusion processes. The Annals of Statistics, 37(1), 223–245.

    Article  Google Scholar 

  • Beskos, A., Papaspiliopoulos, O., Roberts, G., & Fearnhead, P. (2006). Exact and computationally efficient likelihood-based estimation for discretely observed diffusion processes. Journal of the Royal Statistical Society: Series B (Statistical Methodology), 68(3), 333–382. (with Discussion).

    Article  Google Scholar 

  • Buss, K. A., & Goldsmith, H. H. (1998). Fear and anger regulation in infancy: Effects on the temporal dynamics of affective expression. Child Development, 69(2), 359–374. https://doi.org/10.1111/j.1467-8624.1998.tb06195.x.

    Article  PubMed  Google Scholar 

  • Calvet, L. E., & Fisher, A. J. (2004). How to forecast long-run volatility: Regime switching and the estimation of multifractal processes. Journal of Financial Econometrics, 2(1), 49–83. https://doi.org/10.1093/jjfinec/nbh003.

    Article  Google Scholar 

  • Carver, C. S., & Scheier, M. F. (1998). On the self-regulation of behavior. New York, NY: Cambridge University Press.

    Book  Google Scholar 

  • Chow, S.-M., Bendezú, J. J., Cole, P. M., & Ram, N. (2016). A comparison of two-stage approaches for fitting nonlinear ordinary differential equation models with mixed effects. Multivariate Behavioral Research., 51(2–3), 154–184.

    Article  Google Scholar 

  • Chow, S.-M., Grimm, K. J., Guillaume, F., Dolan, C. V., & McArdle, J. J. (2013). Regime-switching bivariate dual change score model. Multivariate Behavioral Research, 48(4), 463–502.

    Article  Google Scholar 

  • Chow, S.-M., Lu, Z., Sherwood, A., & Zhu, H. (2016). Fitting nonlinear ordinary differential equation models with random effects and unknown initial conditions using the stochastic approximation expectation–maximization (SAEM) algorithm. Psychometrika, 81(1), 102–134. https://doi.org/10.1007/s11336-014-9431-z.

    Article  PubMed  Google Scholar 

  • Chow, S.-M., Witkiewitz, K., Grasman, R. P. P. P., & Maisto, S. A. (2015). The cusp catastrophe model as cross-sectional and longitudinal mixture structural equation models. Psychological Methods, 20, 142–164.

    Article  Google Scholar 

  • Chow, S.-M., & Zhang, G. (2013). Nonlinear regime-switching state-space (RSSS) models. Psychometrika, 78(4), 740–768.

    Article  Google Scholar 

  • Cole, P. M., Bendezú, J. J., Ram, N., & Chow, S.-M. (2017). Dynamical systems modeling of early childhood self-regulation. Emotion, 17(4), 684–699. https://doi.org/10.1037/emo0000268.

    Article  PubMed  PubMed Central  Google Scholar 

  • Cole, P. M., Tan, P. Z., Hall, S. E., Zhang, Y., Crnic, K. A., Blair, C. B., et al. (2011). Developmental changes in anger expression and attention focus: Learning to wait. Developmental Psychology, 47(4), 1078.

    Article  Google Scholar 

  • Coleman, J. S. (1968). The mathematical study of change. In H. M. Blalock Jr. & A. Blalock (Eds.), Methodology in social research (pp. 428–478). New York: McGraw-Hill.

    Google Scholar 

  • Collins, L. M., & Wugalter, S. E. (1992). Latent class models for stage-sequential dynamic latent variables. Multivariate Behavioral Research, 28, 131–157.

    Article  Google Scholar 

  • Dolan, C. V., Schmittmann, V. D., Lubke, G. H., & Neale, M. C. (2005). Regime switching in the latent growth curve mixture model. Structural Equation Modeling, 12(1), 94–119.

    Article  Google Scholar 

  • Durham, G. B., & Gallant, A. R. (2002). Numerical techniques for maximum likelihood estimation of continuous-time diffusion processes. Journal of Business & Economic Statistics, 20(3), 297–316.

    Article  Google Scholar 

  • Elerian, O., Chib, S., & Shephard, N. (2001). Likelihood inference for discretely observed nonlinear diffusions. Econometrica, 69(4), 959–993.

    Article  Google Scholar 

  • Elliott, R. J., Aggoun, L., & Moore, J. (1995). Hidden Markov models: Estimation and control. New York: Springer.

    Google Scholar 

  • Fox, E. B., Sudderth, E. B., Jordan, M. I., & Willsky, A. S. (2010). Bayesian nonparametric methods for learning Markov switching processes. IEEE Signal Processing Magazine, 27(6), 43–54. https://doi.org/10.1109/MSP.2010.937999.

    Article  Google Scholar 

  • Fraley, C., Raftery, A.E., Murphy, T. B., & Scrucca, L. (2012). Mclust version 4 for R: Normal mixture modeling for model-based clustering, classification, and density estimation (No. 597). Department of Statistics, University of Washington.

  • Gates, K. M., & Molenaar, P. C. M. (2012). Group search algorithm recovers effective connectivity maps for individuals in homogeneous and heterogeneous samples. Neuroimage, 63, 310–319. https://doi.org/10.1093/jjfinec/nbh003.

    Article  PubMed  Google Scholar 

  • Gelman, A. (1996). Inference and monitoring convergence. In W. R. Gilks, S. Richardson, & D. J. Spiegelhalter (Eds.), Markov chain Monte Carlo in practice (pp. 131–143). Boca Raton, FL: CRC Press LLC.

    Google Scholar 

  • Gelman, A., Meng, X.-L., & Stern, H. (1996). Posterior predictive assessment of model fitness via realized discrepancies. Statistica Sinica, 6(4), 733–760.

    Google Scholar 

  • Geman, S., & Geman, D. (1984). Stochastic relaxation, Gibbs distributions, and the Bayesian restoration of images. IEEE Transactions on Pattern Analysisand Machine Intelligence, 6, 721–741.

    Article  Google Scholar 

  • Ghysels, E., McCulloch, R. E., & Tsay, R. S. (1998). Bayesian inference for periodic regime-switching models. Journal of Applied Econometrics, 13(2), 129–143.

    Article  Google Scholar 

  • Gilks, W. R., Best, N. G., & Tan, K. K. C. (1995). Adaptive rejection metropolis sampling within Gibbs sampling. Journal of the Royal Statistical Society Series C (Applied Statistics), 44(4), 455–472.

    Google Scholar 

  • Gill, J. (2014). Bayesian methods: A social and behavioral sciences approach. Boca Raton, FL: CRC Press.

    Google Scholar 

  • Goldsmith, H. H., & Reilly, J. (1993). Laboratory assessment of temperament-preschool version. University of Oregon: Unpublished manual.

    Google Scholar 

  • Golightly, A., & Wilkinson, D. J. (2008). Bayesian inference for nonlinear multivariate diffusion models observed with error. Computational Statistics & Data Analysis, 52(3), 1674–1693. https://doi.org/10.1016/j.csda.2007.05.019.

    Article  Google Scholar 

  • Hall, D. B. (2000). Zero-inflated Poisson and binomial regression with random effects: A case study. Biometrics, 56(4), 1030–1039.

    Article  Google Scholar 

  • Hastings, W. K. (1970). Monte Carlo sampling methods using Markov chains and their application. Biometrika, 57, 97–100.

    Article  Google Scholar 

  • Jones, R. H. (1984). Fitting multivariate models to unequally spaced data. In E. Parzen (Ed.), Time series analysis of irregularly observed data (Vol. 25, pp. 158–188). New York: Springer.

    Chapter  Google Scholar 

  • Kass, R. E., & Raftery, A. E. (1995). Bayes factors. Journal of the American Statistical Association, 90(430), 773–795.

    Article  Google Scholar 

  • Kim, C.-J., & Kim, J. (2015). Bayesian inference in regime-switching ARMA models with absorbing states: the dynamics of the ex-ante real interest rate under regime shifts. Journal of Business & Economic Statistics, 33(4), 566–578. https://doi.org/10.1080/07350015.2014.979995.

    Article  Google Scholar 

  • Kim, C.-J., & Nelson, C. R. (1999). State-space models with regime switching: Classical and Gibbs-sampling approaches with applications. Cambridge, MA: MIT Press.

    Google Scholar 

  • Kloeden, P. E., & Platen, E. (1999). Numerical solution of stochastic differential equations. Berlin: Springer.

    Google Scholar 

  • Kopp, C. B. (1982). Antecedents of self-regulation: A developmental perspective. Developmental Psychology, 18, 199–214.

    Article  Google Scholar 

  • Lambert, D. (1992). Zero-inflated Poisson regression, with an application to defects in manufacturing. Technometrics, 34(1), 1–14. https://doi.org/10.2307/1269547.

    Article  Google Scholar 

  • Lanza, S. T., & Collins, L. M. (2008). A new SAS procedure for latent transition analysis: Transitions in dating and sexual risk behavior. Developmental Psychology, 44(2), 446–456.

    Article  Google Scholar 

  • Lindström, E. (2012). A regularized bridge sampler for sparsely sampled diffusions. Statistics and Computing, 22(2), 615–623. https://doi.org/10.1007/s11222-011-9255-y.

    Article  Google Scholar 

  • Lu, Z.-H., Chow, S.-M., Sherwood, A., & Zhu, H. (2015). Bayesian analysis of ambulatory blood pressure dynamics with application to irregularly spaced sparse data. The Annals of Applied Statistics, 9(3), 1601–1620. https://doi.org/10.1214/15-AOAS846.

    Article  PubMed  PubMed Central  Google Scholar 

  • Maisto, S. A., Xie, F. C., Witkiewitz, K., Ewart, C. K., Connors, G. J., Zhu, H., et al. (2017). How chronic self-regulatory stress, poor anger regulation, and momentary affect undermine treatment for alcohol use disorder: Integrating social action theory and the dynamic model of relapse. Journal of Social and Clinical Psychology, 36, 238–263. https://doi.org/10.1521/jscp.2017.36.3.238.

    Article  Google Scholar 

  • Mbalawata, I. S., Särkkä, S., & Haario, H. (2013). Parameter estimation in stochastic differential equations with Markov chain Monte Carlo and non-linear Kalman filtering. Computational Statistics, 28(3), 1195–1223. https://doi.org/10.1007/s00180-012-0352-y.

    Article  Google Scholar 

  • Molenaar, P. C. M., & Newell, K. M. (2003). Direct fit of a theoretical model of phase transition in oscillatory finger motions. British Journal of Mathematical and Statistical Psychology, 56, 199–214. https://doi.org/10.1348/000711003770480002.

    Article  PubMed  Google Scholar 

  • Neal, R. M. (2003). Slice sampling. The Annals of Statistics, 31(3), 705–767. https://doi.org/10.1214/aos/1056562461.

    Article  Google Scholar 

  • Nylund, K. L., Muthén, B., Nishina, A., Bellmore, A., & Graham, S. (2006). Stability and instability of peer victimization during middle school: Using latent transition analysis with covariates, distal outcomes, and modeling extensions. https://scholar.google.com/citations?user=cKtI1DQAAAAJ&hl=en#d=gs_md_cita-d&u=%2Fcitations%3Fview_op%3Dview_citation%26hl%3Den%26user%3DcKtI1DQAAAAJ%26citation_for_view%3DcKtI1DQAAAAJ%3AIjCSPb-OGe4C%26tzom%3D360.

  • Oravecz, Z., Tuerlinckx, F., & Vandekerckhove, J. (2011). A hierarchical latent stochastic differential equation model for affective dynamics. Psychological Methods, 16, 468–490. https://doi.org/10.1037/a0024375.

    Article  PubMed  Google Scholar 

  • Oravecz, Z., Tuerlinckx, F., & Vandekerckhove, J. (2016). Bayesian data analysis with the bivariate hierarchical Ornstein–Uhlenbeck process model. Multivariate Behavioral Research, 51(1), 106–119. https://doi.org/10.1080/00273171.2015.1110512.

    Article  PubMed  Google Scholar 

  • Oud, J. H. L., & Jansen, R. A. R. G. (2000). Continuous time state space modeling of panel data by means of SEM. Psychometrika, 65(2), 199–215.

    Article  Google Scholar 

  • Oud, J.H.L., & Singer, H. (Eds.). (2008). Special issue: Continuous time modeling of panel data (Vol. 62(1)).

  • Plummer, M. (2003). JAGS: A program for analysis of Bayesian graphical models using Gibbs sampling. In K. Hornik, F. Leisch, & A. Zeileis (Eds.), Proceedings of the 3rd international workshop on distributed statistical computing (Vol. 124, p. 125). Wien: Technische Universit.

    Google Scholar 

  • Ramsay, J. O., Hooker, G., Campbell, D., & Cao, J. (2007). Parameter estimation for differential equations: A generalized smoothing approach. Journal of Royal Statistical Society: Series B, 69(5), 741–796. https://doi.org/10.1111/j.1467-9868.2007.00610.x. (with Discussion).

    Article  Google Scholar 

  • Roberts, G. O., & Stramer, O. (2001). On inference for partial observed nonlinear diffusion models using the Metropolis–Hastings algorithm. Biometrika, 88, 603–621. https://doi.org/10.1093/biomet/88.3.603.

    Article  Google Scholar 

  • Roeder, K., Lynch, K. G., & Nagin, D. S. (1999). Modeling uncertainty in latent class membership: A case study in criminology. Journal of the American Statistical Association, 94, 766–776. https://doi.org/10.1080/0022250x.2010.509524.

    Article  Google Scholar 

  • Särkkä, S. (2013). Bayesian filtering and smoothing. Hillsdale, NJ: Cambridge University.

    Book  Google Scholar 

  • Singer, H. (1992). The aliasing-phenomenon in visual terms. Journal of Mathematical Sociology, 14(1), 39–49.

    Article  Google Scholar 

  • Singer, H. (2010). SEM modeling with singular moment matrices. Part I: ML-estimation of time series. The Journal of Mathematical Sociology, 34(4), 301–320. https://doi.org/10.1080/0022250x.2010.532259.

    Article  Google Scholar 

  • Singer, H. (2012). SEM modeling with singular moment matrices. Part II: ML-estimation of sampled stochastic differential equations. The Journal of Mathematical Sociology, 36(1), 22–43. https://doi.org/10.1080/0022250x.2010.532259.

    Article  Google Scholar 

  • Solo, V. (2002). Identification of a noisy stochastic heat equation with the EM algorithm. In Proceedings of the 41st IEEE conference on decision and control, 2002. (Vol. 4, pp. 4505–4508). https://doi.org/10.1109/CDC.2002.1185083

  • Spiegelhalter, D. J., Best, N. G., Carlin, B. P., & Van Der Linde, A. (2002). Bayesian measures of model complexity and fit. Journal of the Royal Statistical Society: Series B (Statistical Methodology), 64(4), 583–639.

    Article  Google Scholar 

  • Uhlenbeck, G. E., & Ornstein, L. S. (1930). On the theory of the Brownian motion. Physical review, 36(5), 823.

    Article  Google Scholar 

  • Vehtari, A., Gelman, A., & Gabry, J. (2016). Practical Bayesian model evaluation using leave-one-out cross-validation and WAIC. arXiv (preprint).

  • Voelkle, M. C., Oud, J. H. L., Davidov, E., & Schmidt, P. (2012). An SEM approach to continuous time modeling of panel data: Relating authoritarianism and anomia. Psychological Methods, 17, 176–192. https://doi.org/10.1037/a0027543.

    Article  Google Scholar 

  • Wilhelm, F. H., Grossman, P., & Muller, M. I. (2012). Bridging the gap between the laboratory and the real world: Integrative ambulatory psychophysiology. In M. R. Mehl & T. S. Conner (Eds.), Handbook of research methods for studying daily life (pp. 210–234). New York: Guilford.

    Google Scholar 

  • Yang, J.-W., Tsai, S.-Y., Shyu, S.-D., & Chang, C.-C. (2016). Pairs trading: The performance of a stochastic spread model with regime switching-evidence from the S&P 500. International Review of Economics & Finance, 43, 139–150. https://doi.org/10.1016/j.iref.2015.10.036.

    Article  Google Scholar 

  • Yang, M., & Chow, S.-M. (2010). Using state-space model with regime switching to represent the dynamics of facial electromyography (EMG) data. Psychometrika: Application and Case Studies, 74(4), 744–771.

    Article  Google Scholar 

  • Yümlü, M. S., Gürgen, F. S., Cemgil, A. T., & Okay, N. (2015). Bayesian changepoint and time-varying parameter learning in regime switching volatility models. Digital Signal Processing, 40, 198–212. https://doi.org/10.1016/j.dsp.2015.02.001.

    Article  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Zhao-Hua Lu.

Additional information

Publisher's Note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Funding for this study was provided by NSF Grant SES-1357666, NIH Grants R01MH61388, R01HD07699, R01GM105004, U24EB026436, Penn State Quantitative Social Sciences Initiative and UL TR000127 from the National Center for Advancing Translational Sciences. The article is partly done when Zhao-Hua Lu was in the Pennsylvania State University.

Appendices

Appendix A: JAGS Code

JAGS selects an appropriate MCMC sampler for the parameters automatically from a list of possible samplers, including Gibbs sampler (Geman & Geman, 1984), slice sampler (Neal, 2003), Metropolis–Hastings (Hastings, 1970), and several other possibilities.

figure a
figure b

Appendix B: Full Conditional Distributions of Parameters

Let \(\mathbf{x}_i=(\mathbf{x}_{i,t_{i,1}},\ldots ,\mathbf{x}_{i,t_{i,T_i}})\), \(\mathbf{x}=(\mathbf{x}_{1},\ldots ,\mathbf{x}_{n})\), \(\mathbf{l}_i=(\mathbf{l}_{t_{i,1}},\ldots ,\mathbf{l}_{t_{i,T_i}})\), \(\mathbf{l}=(\mathbf{l}_{1},\ldots ,\mathbf{l}_{n})\), \({\varvec{\theta }}=\{{\varvec{\theta }}_1,\ldots ,{\varvec{\theta }}_R\}\). Let \({\varvec{\alpha }}\) consist of the free parameters in all \({\varvec{\alpha }}^{\mathrm{EP}}_{r_1s_1s_2}\) and \({\varvec{\alpha }}^{\mathrm{PR}}_{r_2s_1s_2}\) in Eq. (8). The posterior distribution of \({\varvec{\theta }}\), \({\varvec{\alpha }}\), and \(\mathbf{l}\) is

$$\begin{aligned} P(\mathbf{l},{\varvec{\theta }},{\varvec{\alpha }}|\mathbf{x})\propto & {} P(\mathbf{x}|\mathbf{l},{\varvec{\theta }})P(\mathbf{l}|{\varvec{\alpha }})p({\varvec{\theta }})p({\varvec{\alpha }}). \end{aligned}$$

The distribution of the process under the Euler approximation and given the latent regime indicator and the parameters, \(P(\mathbf{x}|\mathbf{l},{\varvec{\theta }})\), is

$$\begin{aligned} P(\mathbf{x}|\mathbf{l},{\varvec{\theta }})= & {} \prod _{i=1}^{n}\prod _{k=0}^{T_n-1}P(\mathbf{x}_{i,{t_{i,k+1}}}|\mathbf{x}_{i,{t_{i,k}}},\mathbf{l},{\varvec{\theta }})\nonumber \\&=\prod _{i=1}^{n}\prod _{k=0}^{T_n-1} (2\pi )^{-q/2}|{\Delta {t_{i,k}}}\mathbf{S}\left( \mathbf{x}_{i,{t_{i,k}}},{\varvec{\theta }}_{\mathbf{l}_{{t_{i,k}}}}\right) \mathbf{S}\left( \mathbf{x}_{i,{t_{i,k}}},{\varvec{\theta }}_{\mathbf{l}_{{t_{i,k}}}}\right) ^T|^{-1/2} \nonumber \\&\quad \exp \Bigg \{-\frac{1}{2}\bigg (\Delta \mathbf{x}_{i,{t_{i,k}}} - \mathbf{f}(\mathbf{x}_{i,{t_{i,k}}},{\varvec{\theta }}_{\mathbf{l}_{{t_{i,k}}}})\Delta {t_{i,k}}\bigg )^T\big ({\Delta {t_{i,k}}}\mathbf{S}(\mathbf{x}_{i,{t_{i,k}}},{\varvec{\theta }}_{\mathbf{l}_{{t_{i,k}}}})\mathbf{S}(\mathbf{x}_{i,{t_{i,k}}},{\varvec{\theta }}_{\mathbf{l}_{{t_{i,k}}}})^T\big )^{-1}\nonumber \\&\qquad \left( \Delta \mathbf{x}_{i,{t_{i,k}}} - \mathbf{f}\left( \mathbf{x}_{i,{t_{i,k}}},{\varvec{\theta }}_{\mathbf{l}_{{t_{i,k}}}}\right) \Delta {t_{i,k}}\right) \Bigg \}. \end{aligned}$$
(17)

The distribution of the latent regime indicator given the parameters, \(P(\mathbf{l}|{\varvec{\alpha }})\), is

$$\begin{aligned} P(\mathbf{l}|{\varvec{\alpha }})= & {} \prod _{i=1}^{n}\prod _{k=0}^{T_n-1}\prod _{j=1}^{q}p\left( l_{j{t_{i,k+1}}}|\mathbf{l}_{{t_{i,k}}}\right) \nonumber \\= & {} \prod _{i=1}^{n}\prod _{k=0}^{T_n-1}\prod _{j=1}^{q}\frac{\exp \big \{{\varvec{\alpha }}^{(j)T}_{l_{j{t_{i,k+1}}}\mathbf{l}_{{t_{i,k}}}}\mathbf{u}_i\big \}}{\sum _{r=1}^R\exp \big \{{\varvec{\alpha }}^{(j)T}_{r,\mathbf{l}_{{t_{i,k}}}}\mathbf{u}_i\big \}}. \end{aligned}$$
(18)

The full conditional distribution of \({l^{\mathrm{EP}}_{{t_{i,k}}}}\) is

$$\begin{aligned} P\left( {l^{\mathrm{EP}}_{{t_{i,k}}}}|\cdot \right)\propto & {} P\left( \mathrm{EP}_{i,{t_{i,k+1}}}|\mathrm{EP}_{i,{t_{i,k}}},{l^{\mathrm{EP}}_{{t_{i,k}}}},{\varvec{\theta }}\right) P\left( {l^{\mathrm{EP}}_{{t_{i,k+1}}}}|\mathbf{l}_{{t_{i,k}}},{\varvec{\alpha }}\right) P\left( {l^{\mathrm{EP}}_{{t_{i,k}}}}|\mathbf{l}_{{t_{i,k-1}}},{\varvec{\alpha }}\right) , \end{aligned}$$
(19)

which is a categorical distribution. The probabilities of all categories can be calculated by standardizing the right-hand side of Eq. (19).

The full conditional distribution of \({\varvec{\alpha }}\) is proportional to \(P(\mathbf{l}|{\varvec{\alpha }})P({\varvec{\alpha }})\), where \(P({\varvec{\alpha }})\) is the prior distribution of \({\varvec{\alpha }}\) defined in Eq. (8). The full conditional distribution of \({\varvec{\alpha }}\) is not standard. MCMC algorithms may be employed to generate samples from the distribution, for instance, via Metropolis–Hastings algorithm (Hastings, 1970) or the slice sampler (Neal, 2003).

The full conditional distribution of \({\varvec{\theta }}\) is model-dependent. In the ZI-OU model, given the prior distributions in Eq. (7), the full conditional distributions of the parameters in the OU model are as follows.

$$\begin{aligned}&\beta _{\mathrm{EP},l}|\cdot \sim N\left( {\tilde{\beta }}_{\mathrm{EP},0l},{\tilde{\sigma }}^2_{\beta _{\mathrm{EP},l}}\right) I(0,\infty ), ~~~~ \beta _{\mathrm{PR},l}|\cdot \sim N\left( {\tilde{\beta }}_{\mathrm{PR},0l},{\tilde{\sigma }}^2_{\beta _{\mathrm{PR},l}}\right) I(0,\infty ),\\&\mu _{\mathrm{EP},l}|\cdot \sim N\left( {\tilde{\mu }}_{\mathrm{EP},0l},{\tilde{\sigma }}^2_{\mu _{\mathrm{EP},l}}\right) , ~~~~ \mu _{\mathrm{PR},l}|\cdot \sim N\left( {\tilde{\mu }}_{\mathrm{PR},0l},{\tilde{\sigma }}^2_{\mu _{\mathrm{PR},l}}\right) ,\\&\sigma _{\mathrm{EP},l}|\cdot \sim IG({\tilde{a}}_{\mathrm{EP},1l},{\tilde{a}}_{\mathrm{EP},2l}), ~~~~ \sigma _{\mathrm{PR},l}|\cdot \sim IG({\tilde{a}}_{\mathrm{PR},1l},\tilde{a}_{\mathrm{PR},2l}), \end{aligned}$$

where

$$\begin{aligned} {\tilde{\sigma }}^2_{\beta _{\mathrm{EP},l}}= & {} \Bigg (\frac{1}{\sigma ^2}\sum _{i=1}^n\sum _{{l^{\mathrm{EP}}_{{t_{i,k}}}}=l}{(\mu _{\mathrm{EP},{l^{\mathrm{EP}}_{{t_{i,k}}}}}-\mathrm{EP}_{i,{t_{i,k}}})^2\Delta {t_{i,k}}}+\frac{1}{\sigma ^2_{\beta _{\mathrm{EP},l}}}\Bigg )^{-1},\\ {\tilde{\beta }}_{\mathrm{EP},0l}= & {} {\tilde{\sigma }}^2_{\beta _{\mathrm{EP},l}}\Bigg (\frac{1}{\sigma ^2}\sum _{i=1}^n\sum _{{l^{\mathrm{EP}}_{{t_{i,k}}}}=l}{(\mu _{\mathrm{EP},{l^{\mathrm{EP}}_{{t_{i,k}}}}}-\mathrm{EP}_{i,{t_{i,k}}})(\mathrm{EP}_{i,{t_{i,k+1}}} -\mathrm{EP}_{i,{t_{i,k}}})}+\frac{\beta _{\mathrm{EP},0l}}{\sigma ^2_{\beta _{\mathrm{EP},l}}}\Bigg ),\\ {\tilde{\sigma }}^2_{\mu _{\mathrm{EP},l}}= & {} \Bigg (\frac{\beta _{\mathrm{EP},l}^2}{\sigma ^2}\sum _{i=1}^n\sum _{{l^{\mathrm{EP}}_{{t_{i,k}}}}=l}{\Delta {t_{i,k}}}+\frac{1}{\sigma ^2_{\mu _{\mathrm{EP},l}}}\Bigg )^{-1},\\ {\tilde{\mu }}_{\mathrm{EP},0l}= & {} {\tilde{\sigma }}^2_{\mu _{\mathrm{EP},l}}\Bigg (\frac{\beta _{\mathrm{EP},l}}{\sigma ^2}\sum _{i=1}^n\sum _{{l^{\mathrm{EP}}_{{t_{i,k}}}}=l}{(\mathrm{EP}_{i,{t_{i,k+1}}} -\mathrm{EP}_{i,{t_{i,k}}}+\beta _{\mathrm{EP},l}\mathrm{EP}_{i,{t_{i,k}}}\Delta {t_{i,k}})}+\frac{\mu _{\mathrm{EP},0l}}{\sigma ^2_{\mu _{\mathrm{EP},l}}}\Bigg ),\\ \tilde{a}_{\mathrm{EP},1l}= & {} a_{\mathrm{EP},1l}+\frac{1}{2}\sum _{i=1}^n\sum _{k=0}^{T_i-1}I({l^{\mathrm{EP}}_{{t_{i,k}}}}=l), \text {and}\\ \tilde{a}_{\mathrm{EP},2l}= & {} a_{\mathrm{EP},2l}+\frac{1}{2}\sum _{i=1}^n\sum _{{l^{\mathrm{EP}}_{{t_{i,k}}}}=l} \frac{\big ((\mathrm{EP}_{i,{t_{i,k+1}}} - \mathrm{EP}_{i,{t_{i,k}}}) - \beta _{\mathrm{EP},{l^{\mathrm{EP}}_{{t_{i,k}}}}}(\mu _{\mathrm{EP},{l^{\mathrm{EP}}_{{t_{i,k}}}}}-\mathrm{EP}_{i,{t_{i,k}}})\Delta {t_{i,k}}\big )^2}{\Delta {t_{i,k}}}, \end{aligned}$$

and the parameters for the PR process can be derived similarly.

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Lu, ZH., Chow, SM., Ram, N. et al. Zero-Inflated Regime-Switching Stochastic Differential Equation Models for Highly Unbalanced Multivariate, Multi-Subject Time-Series Data. Psychometrika 84, 611–645 (2019). https://doi.org/10.1007/s11336-019-09664-7

Download citation

  • Received:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s11336-019-09664-7

Keywords

Navigation