nwsbm: Stochastic block models for networks in Stata. Manual

This is the user manual and reference of nwsbm, series 1.0 (examples produced with version 1.0.0 and the nwcommands core 3.29.0), a Stata package for stochastic block models of networks: the actors are sorted into blocks, the distribution of a tie depends only on the blocks of the two actors, and the number of blocks is chosen by the integrated classification likelihood (ICL). nwsbm builds on the nwcommands core package and follows the R packages blockmodels and sbm (variational EM, objective, ICL, model names) and greed (exact ICL, degree-corrected models, greedy search). It fits Bernoulli, Poisson and Gaussian models for undirected and directed one-mode networks with missing ties, the degree-corrected Poisson model, the latent block model for two-mode networks, and dyadic covariates with standard errors of the coefficients. The manual describes the installation, the models and the estimator, the syntax and every option, the selection of the number of blocks, the exact ICL and the greedy search, covariates, two-mode networks, the postestimation commands and stored results, the plots (blocked matrix, expected ties, memberships, block graph, ICL path), the comparison of models, the validation against sbm, blockmodels and greed as recorded in the test suite of the package, and the limits. Worked examples use the karate club, the law firm of Lazega and the Southern women of Davis, Gardner and Gardner. nwsbm requires the nwcommands core package (version 3.29.0 or later) and Stata 17 or later and is meant for researchers who work in Stata. It is not a replacement for the R packages, which remain the reference implementations, and it is not affiliated with or endorsed by their authors. The software is free software under the GNU General Public License, version 3. The package and the manual were prepared with the help of an AI coding assistant working under the author's direction, as stated in the manual. Please cite this manual (all-versions DOI) and report the exact version printed by nwsbm version.

Authors

Institutions

Publication Details

Journal
Zenodo (CERN European Organization for Nuclear Research)
Published
2026-11-20
DOI
https://doi.org/10.5281/zenodo.24398296
Primary Topic
Complex Network Analysis Techniques
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
NOV
article

nwsbm: Stochastic block models for networks in Stata. Manual

Thomas Grund
2 links
Zenodo (CERN European Organization for Nuclear Research)
Complex Network Analysis Techniques
article

nwsbm: Stochastic block models for networks in Stata. Manual

Thomas Grund
article en

Abstract

This is the user manual and reference of nwsbm, series 1.0 (examples produced with version 1.0.0 and the nwcommands core 3.29.0), a Stata package for stochastic block models of networks: the actors are sorted into blocks, the distribution of a tie depends only on the blocks of the two actors, and the number of blocks is chosen by the integrated classification likelihood (ICL). nwsbm builds on the nwcommands core package and follows the R packages blockmodels and sbm (variational EM, objective, ICL, model names) and greed (exact ICL, degree-corrected models, greedy search). It fits Bernoulli, Poisson and Gaussian models for undirected and directed one-mode networks with missing ties, the degree-corrected Poisson model, the latent block model for two-mode networks, and dyadic covariates with standard errors of the coefficients. The manual describes the installation, the models and the estimator, the syntax and every option, the selection of the number of blocks, the exact ICL and the greedy search, covariates, two-mode networks, the postestimation commands and stored results, the plots (blocked matrix, expected ties, memberships, block graph, ICL path), the comparison of models, the validation against sbm, blockmodels and greed as recorded in the test suite of the package, and the limits. Worked examples use the karate club, the law firm of Lazega and the Southern women of Davis, Gardner and Gardner. nwsbm requires the nwcommands core package (version 3.29.0 or later) and Stata 17 or later and is meant for researchers who work in Stata. It is not a replacement for the R packages, which remain the reference implementations, and it is not affiliated with or endorsed by their authors. The software is free software under the GNU General Public License, version 3. The package and the manual were prepared with the help of an AI coding assistant working under the author's direction, as stated in the manual. Please cite this manual (all-versions DOI) and report the exact version printed by nwsbm version.

Zenodo (CERN European Organization for Nuclear Research)
RWTH Aachen University (DE)
Complex Network Analysis Techniques
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Laika access coming soon