![]()
Haziq Jamil1,2,3,*
1Computer, Electrical and Mathematical Sciences and Engineering (CEMSE) Division,
King Abdullah University of Science and Technology (KAUST), Thuwal, Kingdom of Saudi Arabia
2Mathematical Sciences, Faculty of Science, Universiti Brunei Darussalam (UBD), Brunei Darussalam
3Department of Statistics, London School of Economics and Political Science (LSE), London, United Kingdom
Received October 2018 (PhD) · Accepted August 2025 (KAUST) ·
Abstract. I am a statistician working on theory, methods, and computation for latent variable models. These models infer hidden traits, and the relationships between them, from indirect, multivariate measurements. Contemporary data are larger, noisier, and more richly structured than ever, and they call for new tools to analyse them. As a Research Specialist in Håvard Rue’s BAYESCOMP group at KAUST, I aim to advance scalable Bayesian methods for latent variable models, starting with fast and accurate inference for structural equation models (SEM) built on integrated nested Laplace approximations (INLA; Rue et al., 2009). The project is funded by a USD 900,000 KAUST Competitive Research Grant, on which I am co-investigator. Earlier work covers bias-reduced regularisation for small-sample SEM and limited-information methods for categorical data under complex sampling. I hold an Assistant Professorship in Statistics at UBD (on leave) and a Visiting Fellow position in the Department of Statistics at the LSE (2024–2027). I studied at Warwick, where David Firth supervised my undergraduate research project, and at the LSE, where my PhD on nonparametric regression using information-dependent priors was supervised by Wicher Bergsma and Irini Moustaki. My thesis was awarded the Zellner Thesis Award (honourable mention) by the American Statistical Association in 2020. As a strong proponent of open-source software, I write my methods in R and make them freely available on GitHub, where anyone is welcome to use, adapt, and contribute to them.
Keywords: latent variable models; structural equation models; Bayesian computation; INLA; pairwise likelihood; spatio-temporal models.
*All correspondence should be addressed to Haziq Jamil, haziq.jamil [at] kaust.edu.sa
1 Introduction
All random variables are latent, but some random variables are more latent than others.
With apologies to George Orwell
Student ability, anxiety severity, food insecurity, institutional trust, and job satisfaction are central constructs in education, health, and the social sciences, yet none can be observed directly. Latent variable modelling, which includes factor analysis, structural equation models (SEM), and item response theory, is the statistical framework for studying them. Bayesian inference suits these models well: it offers principled uncertainty quantification, small-sample regularisation, and flexible model specification. Despite its ubiquity, current computational approaches like Bayesian Markov chain Monte Carlo (MCMC) struggle to scale with modern data complexities. The bottleneck is acute in applied psychometrics, where measurements are noisy, outcomes hierarchical, and data highly dependent, and where careful modelling follows an iterative workflow of specification, criticism, and refinement. My work aims to remove most of that cost.
2 Research programme
INLA was designed for models with only a handful of hyperparameters, whereas the typical SEM has dozens. We therefore built a bespoke and efficient algorithm for latent variable models from the ground up, distilled from the INLA methodology.
Theorem 1 (Fast approximate inference) Let ℳ be a latent variable model whose log-posterior \(\log \pi(\vartheta \mid y)\) and its gradient are cheap to evaluate, and for which \(\log \pi(\vartheta \mid y)\) is sufficiently close to quadratic in some unconstrained parameterisation. Then accurate approximate Bayesian inference for ℳ is possible at a small fraction of the cost of Markov chain Monte Carlo.
Proof. Approximate the joint posterior by a Gaussian that matches the posterior mode and the curvature there, correct each marginal for skewness, and obtain everything else by sampling from a Gaussian copula built on these marginals. The methodology for normal-theory SEM is detailed in Jamil and Rue (2026a), and the software in Jamil and Rue (2026b). Model comparison by leave-one-cluster-out cross-validation is also available, in closed form and without refitting (Alhyari et al., 2026).
Remark 1. The conditions of Theorem 1 hold for well-identified normal-theory SEM, multilevel models included (Alhyari et al., 2026; Jamil & Rue, 2026b). Accuracy degrades in weakly identified models and in the lower tails of variances near zero (Jamil & Rue, 2026a). Extending the method to categorical data is ongoing work (see Section 5).
Remark 2 (Availability). Students, researchers, and academics who would like to collaborate on the problems in Section 5 are welcome to get in touch. I am also happy to give talks and short courses on Bayesian SEM and INLAvaan.
3 News
-
upcoming Approximate Bayesian inference beyond structural equation models. Psychoco 2027, Maastricht University, Maastricht, Netherlands.
-
upcoming Approximate Bayesian inference for structural equation models. CFE-CMStatistics 2026, HTW Berlin, Berlin, Germany (online).
-
Advancing scalable Bayesian methods for latent variable modelling. KAUST Statistics Research Day, KAUST, Thuwal, Saudi Arabia.
-
Approximate Bayesian inference for structural equation models (SEM): The INLA approach. Centre for Educational Measurement (CEMO) seminar, University of Oslo, Oslo, Norway.
-
Approximate Bayesian inference for structural equation models (SEM): The INLA approach. International Meeting of the Psychometric Society (IMPS) 2026, Yonsei University, Seoul, South Korea.
4 Software
The methods of Section 2 are implemented in the following R package. With models fitting in seconds, it makes the iterative Bayesian psychometric workflow feasible in applied work.
CRANdocscode
Please cite:
Jamil, H., & Rue, H. (2026). Implementation and workflows for INLA-based approximate Bayesian structural equation modelling [Preprint]. arXiv. https://doi.org/10.48550/arXiv.2604.00671
@misc{jamil2026implementation,
author = {Jamil, Haziq and Rue, Håvard},
title = {Implementation and workflows for {INLA-based} approximate {Bayesian} structural equation modelling},
year = {2026},
eprint = {2604.00671},
archiveprefix = {arXiv},
doi = {10.48550/arXiv.2604.00671}
}
Listing 1. Fit a Bayesian SEM with INLAvaan, using the lavaan model syntax.
install.packages("INLAvaan")
library(INLAvaan)
model <- "
# Measurement model
ind60 =~ x1 + x2 + x3
dem60 =~ y1 + y2 + y3 + y4
dem65 =~ y5 + y6 + y7 + y8
# Structural model
dem60 ~ ind60
dem65 ~ ind60 + dem60
# Residual covariances
y1 ~~ y5
y2 ~~ y4 + y6
y3 ~~ y7
y4 ~~ y8
y6 ~~ y8
"
fit <- asem(model, data = lavaan::PoliticalDemocracy)
summary(fit)5 Discussion and future work
Having laid the foundation for fast approximate inference in SEM, I see several directions with genuinely open questions. I would welcome collaborators on any of them.
- Beyond normal-theory SEM. Binary, ordinal, and count outcomes break the closed-form likelihood that makes normal-theory SEM fast, and their posteriors can be sharply skewed. How far can Laplace-type approximations be pushed before they lose accuracy, and can one engine serve mixed data, where continuous, ordinal, and count indicators load on the same factors?
- Space and time. Respondents share neighbourhoods, and constructs evolve between survey waves. Continuous-time SEM, areal spatial effects, and Gaussian random fields with Matérn covariance through the SPDE approach each add a latent field to a model that is already latent (Figure 1). Can the sparse precision structure that makes INLA fast for spatial models be married to the dense covariance structure of SEM?
- Discrete latent variables. Latent class and mixture models posit unobserved categories rather than continua, so the latent variables are no longer Gaussian, a case that falls outside classical INLA. Can deterministic approximation still work when the latent space is discrete and the posterior is multimodal?
- Priors that mean something. Default priors for SEM are often chosen for convenience and behave poorly near the boundary, where variances approach zero. Penalised complexity priors shrink towards a simpler base model at an interpretable rate. What is the right base model, and the right parameterisation, for loadings, variances, and above all correlation matrices?
Data and code availability
All methods are released as open-source R packages on CRAN and GitHub. Slides for most talks are on this site (see Talks). The benchmark behind Figure 2 fits the PoliticalDemocracy data of lavaan (Bollen, 1989) with INLAvaan 0.4.1.9000 and blavaan 0.6.1, run on 2026-12-01.
Acknowledgements
I thank my coauthors, students, and colleagues at KAUST, UBD, and the LSE. This work is supported by KAUST Competitive Research Grant URF/1/6921-01-01.
Declaration of generative AI use
In preparing this site, I used Claude Opus 5.5 (Anthropic) to help write code, design the layout, and edit text. I reviewed and edited all content and take full responsibility for it.
References
-
Jamil, H., & Rue, H. (2026a). Approximate Bayesian inference for structural equation models using integrated nested Laplace approximations [Preprint]. arXiv. https://doi.org/10.48550/arXiv.2603.25690
Markov chain Monte Carlo (MCMC) methods remain the mainstay of Bayesian estimation of structural equation models (SEM), though they often incur a high computational cost. We present a bespoke approximate Bayesian approach to SEM, drawing on ideas from the integrated nested Laplace approximation (INLA; Rue et al., 2009, J. R. Stat. Soc., B: Stat. Methodol.) framework. After analytically integrating out the latent variables, we implement a simplified Laplace approximation that profiles the posterior using an efficient gradient-based volume correction, allowing for parametric skew-normal estimation of the marginals. A variational Bayes correction further refines the centre of the joint Gaussian approximation; marginal profiling implicitly recovers the same location correction to leading order. Essential quantities, including factor scores and model-fit indices, are obtained via a Gaussian copula sampling scheme. On a benchmark SEM, inference completes in seconds with close agreement to MCMC. A simulation study stresses the approximation along sample size, identification, boundary proximity, and model dimension. Accuracy remains high across the examined sample sizes and model dimensions, with degradation concentrated in weakly identified settings and in the lower tails of variances near the zero boundary.
@misc{jamil2026approximate, author = {Jamil, Haziq and Rue, Håvard}, title = {Approximate {Bayesian} inference for structural equation models using integrated nested {Laplace} approximations}, year = {2026}, eprint = {2603.25690}, archiveprefix = {arXiv}, doi = {10.48550/arXiv.2603.25690} } -
Jamil, H., & Rue, H. (2026b). Implementation and workflows for INLA-based approximate Bayesian structural equation modelling [Preprint]. arXiv. https://doi.org/10.48550/arXiv.2604.00671
Bayesian structural equation modelling (BSEM) offers many advantages such as principled uncertainty quantification, small-sample regularisation, and flexible model specification. However, the Markov chain Monte Carlo (MCMC) methods on which it relies can be slow for the iterative cycle of specification, criticism, and refinement that careful psychometric practice demands. We present INLAvaan, an R package for fast, approximate Bayesian SEM built around the Integrated Nested Laplace Approximation (INLA) framework for structural equation models developed by Jamil and Rue (2026, arXiv:2603.25690). This paper serves as a companion manuscript that describes the architectural decisions and computational strategies underlying the package. Two substantive applications – a 256-parameter bifactor circumplex model and a multilevel mediation model with full-information missing-data handling – demonstrate how INLAvaan makes the iterative Bayesian workflow feasible in applied psychometric work.
@misc{jamil2026implementation, author = {Jamil, Haziq and Rue, Håvard}, title = {Implementation and workflows for {INLA-based} approximate {Bayesian} structural equation modelling}, year = {2026}, eprint = {2604.00671}, archiveprefix = {arXiv}, doi = {10.48550/arXiv.2604.00671} } -
Alhyari, M., Jamil, H., Montcho, H., & Rue, H. (2026). Deterministic leave-one-cluster-out cross-validation for multilevel Bayesian structural equation models [Preprint]. arXiv. https://doi.org/10.48550/arXiv.2609.00670
We introduce a closed-form, refit-free procedure for leave-one-cluster-out (LOCO) cross-validation in multilevel Gaussian Bayesian structural equation models (SEMs), together with predictive scoring of every nested submodel. Conditional independence of clusters given the parameters expresses the cluster-deleted posterior as a functional of the full posterior. The LOCO predictive density is then a harmonic mean of the cluster likelihood, computable from a single fit in INLAvaan, the integrated nested Laplace approximation package for Bayesian SEM. We evaluate the harmonic-mean expectation in closed form through a fully exponential Laplace approximation of the reciprocal cluster likelihood under a Gaussian posterior; candidate structural restrictions follow by Gaussian conditioning of the same Laplace summary. The resulting Taylor elpd (expected log predictive density) scores are fully deterministic, requiring neither refitting nor Monte Carlo sampling, so the variance pathology of the naive harmonic-mean estimator does not arise. A direct-sum decomposition of the compound-symmetric cluster covariance makes the cost independent of cluster size, orders of magnitude below brute-force refitting. We validate against brute-force refits and Markov chain Monte Carlo in simulation, and illustrate the procedure on school-safety climate in PISA 2022 and on 16 candidate structures linking personality and well-being in the MIDUS sibling sample.
@misc{alhyari2026deterministic, author = {Alhyari, Mohammad and Jamil, Haziq and Montcho, Hans and Rue, Håvard}, title = {Deterministic leave-one-cluster-out cross-validation for multilevel {Bayesian} structural equation models}, year = {2026}, eprint = {2609.00670}, archiveprefix = {arXiv}, doi = {10.48550/arXiv.2609.00670} } -
Jamil, H., Rosseel, Y., Kemp, O., & Kosmidis, I. (2026). Bias-reduced estimation of structural equation models. Structural Equation Modeling: A Multidisciplinary Journal, 33(3), 376–392. https://doi.org/10.1080/10705511.2025.2610462
Finite-sample bias is a pervasive challenge in the estimation of structural equation models (SEMs), especially when sample sizes are small or measurement reliability is low. A range of methods have been proposed to improve finite-sample bias in the SEM literature, ranging from analytic bias corrections to resampling-based techniques, with each carrying trade-offs in scope, computational burden, and statistical performance. We apply the reduced-bias M-estimation framework (RBM, Kosmidis & Lunardon, 2024, J. R. Stat. Soc. Series B Stat. Methodol.) to SEMs. The RBM framework is attractive as it requires only first- and second-order derivatives of the log-likelihood, which renders it both straightforward to implement, and computationally more efficient compared to resampling-based alternatives such as bootstrap and jackknife. It is also robust to departures from modelling assumptions. Through extensive simulations studies under a range of experimental conditions, we illustrate that RBM estimators consistently reduce mean bias in the estimation of SEMs without inflating mean squared error. They also deliver improvements in both median bias and inference relative to maximum likelihood estimators, while maintaining robustness under non-normality. Our findings suggest that RBM offers a promising, practical, and broadly applicable tool for mitigating bias in the estimation of SEMs, particularly in small-sample research contexts.
@article{jamil2026biasreduced, author = {Jamil, Haziq and Rosseel, Yves and Kemp, Oliver and Kosmidis, Ioannis}, title = {Bias-reduced estimation of structural equation models}, journal = {Structural Equation Modeling: A Multidisciplinary Journal}, year = {2026}, volume = {33}, number = {3}, pages = {376--392}, doi = {10.1080/10705511.2025.2610462} } -
Jamil, H. (2025). A spatio-temporal analysis of house prices in Brunei Darussalam. Quality & Quantity, 59(6), 5089–5120. https://doi.org/10.1007/s11135-025-02164-0
This paper presents the first spatio-temporal analysis of property prices in Brunei Darussalam, a small, resource-rich economy with distinct housing market characteristics. Despite global interest in quantitative housing market analyses, Brunei’s market remains underexplored, with prior studies predominantly qualitative. Addressing this gap, \(N=3,763\) residential transactions from 2015 to 2023 were analysed using Conditional Autoregressive (CAR) priors to model spatial dependencies and temporal trends in house prices accounting for other price determinants. Emerging Hotspot Analysis was then employed to classify price clustering across time. Key findings revealed significant spatial autocorrelation (\(\rho=0.43\)) and temporal persistence best modeled by an autoregressive structure of order two, indicating that market reactions to changes can extend up to six months. The results demonstrate the critical role of spatial and temporal factors in shaping property prices, providing actionable insights for policy interventions and real estate market analysis, particularly in addressing disparities between urban and rural housing markets.
@article{jamil2025a, author = {Jamil, Haziq}, title = {A spatio-temporal analysis of house prices in {Brunei} {Darussalam}}, journal = {Quality & Quantity}, year = {2025}, volume = {59}, number = {6}, pages = {5089--5120}, doi = {10.1007/s11135-025-02164-0} } -
Jamil, H., Moustaki, I., & Skinner, C. (2025). Pairwise likelihood estimation and limited-information goodness-of-fit test statistics for binary factor analysis models under complex survey sampling. British Journal of Mathematical and Statistical Psychology, 78(1), 258–285. https://doi.org/10.1111/bmsp.12358
This paper discusses estimation and limited information goodness-of-fit test statistics in factor models for binary data using pairwise likelihood estimation and sampling weights. The paper extends the applicability of pairwise likelihood estimation for factor models with binary data to accommodate complex sampling designs. Additionally, it introduces two key limited information test statistics: the Pearson chi-squared test and the Wald test. To enhance computational efficiency, the paper introduces modifications to both test statistics. The performance of the estimation and the proposed test statistics under simple random sampling and unequal probability sampling is evaluated using simulated data.
@article{jamil2025pairwise, author = {Jamil, Haziq and Moustaki, Irini and Skinner, Chris}, title = {Pairwise likelihood estimation and limited-information goodness-of-fit test statistics for binary factor analysis models under complex survey sampling}, journal = {British Journal of Mathematical and Statistical Psychology}, year = {2025}, volume = {78}, number = {1}, pages = {258--285}, doi = {10.1111/bmsp.12358} }
Appendix A. Biography
Education
- PhD in Statistics, London School of Economics and Political Science (2018)
- MSc in Statistics with Distinction, London School of Economics and Political Science (2014)
- BSc and Master of Mathematics, Operational Research, Statistics and Economics (MMORSE) with First Class Honours, University of Warwick (2010)
Career
- Research Specialist, King Abdullah University of Science and Technology (2025–present)
- Visiting Fellow, Department of Statistics, London School of Economics and Political Science (2024–2027)
- Assistant Professor in Statistics, Universiti Brunei Darussalam (2019–present, on leave since 2025)
- Research Officer, Centre of Science and Technology Research and Development, Ministry of Defence, Brunei (2010–2013, 2018–2019)
Service
- Associate Editor, Journal of Statistical Theory and Applications (2025–present)
- Review Editor, Frontiers in Applied Mathematics and Statistics (2020–2023)
- Contributor, lavaan R package (2023–present)
- Chair, Brunei R User Group (2024–2026)
- Referee for journals including Psychometrika, Annals of Applied Statistics, Statistics and Computing, Journal of the Royal Statistical Society: Series C, Behavior Research Methods, Quality & Quantity, and SoftwareX
For programmes and introductions, copy whichever length fits.
Short (40 words)
Haziq Jamil is a Research Specialist at KAUST and an Assistant Professor in Statistics (on leave) at Universiti Brunei Darussalam. He develops scalable Bayesian methods and open-source R software for latent variable models. He holds a PhD in Statistics from the LSE.
Medium (90 words)
Haziq Jamil is a Research Specialist in Håvard Rue’s BAYESCOMP group at King Abdullah University of Science and Technology (KAUST), on leave from his post as Assistant Professor in Statistics at Universiti Brunei Darussalam, and a Visiting Fellow at the London School of Economics. He works on theory, methods, and computation for latent variable models, and is co-investigator on a KAUST Competitive Research Grant to develop fast Bayesian inference for structural equation models. He is the author of the R package INLAvaan. He holds a PhD in Statistics from the LSE.
Long (150 words)
Haziq Jamil is a Research Specialist in the Bayesian Computational Statistics and Modeling (BAYESCOMP) group, led by Håvard Rue, at King Abdullah University of Science and Technology (KAUST). He is on leave from his post as Assistant Professor in Statistics at Universiti Brunei Darussalam, and is a Visiting Fellow in the Department of Statistics at the London School of Economics and Political Science (2024–2027). His research covers theory, methods, and computation for latent variable models. His current work develops fast approximate Bayesian inference for structural equation models using integrated nested Laplace approximations, funded by a KAUST Competitive Research Grant on which he is co-investigator. Earlier work covers bias-reduced estimation and pairwise likelihood methods for categorical data. He obtained his PhD in Statistics from the LSE in 2018, and his thesis received an honourable mention for the Zellner Thesis Award of the American Statistical Association. He is the author of several open-source R packages, including INLAvaan.
Appendix B. Headshot
Full resolution (2996 × 2996, JPEG): download. Free to use for event programmes.