betaFeedback

WorksMathematics

Deep Negative Binomial Autoregression for Sparse Spatio-Temporal Counts: Estimation and Predictive Distribution Bounds

Abstract

We study estimation and probabilistic forecasting for sparse, overdispersed count panels using DeepNB-STAR, a negative binomial autoregression whose log-mean and log-size are outputs of a deep ReLU network of temporal and neighboring summaries of the past, fitted by maximum likelihood. We prove an oracle inequality for the Hellinger risk along the observed trajectory without mixing assumptions, rates governed by compositional smoothness with a matching lower bound for a Hölder subclass, geometric absolute regularity, and bounds on the error of h-step predictive distributions of order h^{1/2} times the root estimation risk plus a Monte Carlo term. All results hold for a size that depends on the covariates, and the estimation bounds hold under arbitrary dependence between sites, with the number of time points as sample size. On four Japanese surveillance panels, DeepNB-STAR has a weighted interval score 0.6% to 1.0% below that of a three-member ensemble of Temporal Fusion Transformers on every panel, distinguishable from zero only on the held-out panel. Fitted mean and size functions are reported with exploratory bootstrap intervals. Nominal 95% prediction intervals for national totals cover only 81% to 92% of weeks: the joint predictive law, unlike the estimator, relies on conditional independence across sites.

Introduction

Deep neural networks are now a standard tool for probabilistic forecasting of large panels of related time series. Architectures such as DeepAR (Salinas et al., 2020) and the Temporal Fusion Transformer (TFT; Lim et al., 2021) are trained on all series jointly, output the parameters or the quantiles of a predictive distribution, and are applied in demand planning, energy and public health. Many of the panels encountered in these applications consist of counts that are sparse, bursty and overdispersed, and that are dependent across both time and space; examples include disease surveillance, traffic flows (He et al., 2023) and event records, for which deep temporal encoders have been paired with negative binomial and zero-inflated negative binomial likelihood heads in a Bayesian pipeline (Huang et al., 2026). Weekly surveillance counts of a notifiable disease are a typical example: most site-weeks have no case, a few sites have bursts of several dozen cases, the variance is many times the mean, and neighboring sites move together. Despite the empirical success of deep forecasters on such data, their statistical behavior is largely unknown. It is not clear at what rate the estimated predictive distribution approaches the truth, whether that rate can be improved, or what the estimation error implies for a prediction interval issued several steps ahead.

A substantial body of work addresses the first two questions for nonparametric regression with independent observations. Deep networks with the rectified linear unit (ReLU) activation approxi-

©2026 Hsin-Hsiung Huang.

License: CC-BY 4.0, see https://creativecommons.org/licenses/by/4.0/. mate smooth functions efficiently (Yarotsky, 2017), and least squares estimators over such networks attain minimax optimal rates for smooth and for composition-structured regression functions [12] (Bauer and Kohler 2019; Kohler and Langer 2021; Jiao et al. 2023), as well as for non-smooth ones (Imaizumi and Fukumizu, 2019). The key insight of this line of work is that the rate depends on the intrinsic dimension of the components of the target function and not on the number of covariates. Extensions cover general loss functions (Farrell et al., 2021) and high-dimensional factor structure (Fan and Gu, 2024), and network rates have been combined with structured response models, for instance for responses in metric spaces [7] (Han and Huang 2026). For dependent observations, generalization bounds are available under mixing conditions (Yu, 1994; Mohri and Rostamizadeh, 2008), and rates over deep networks have been established for least squares with mixing sequences and nonlinear autoregressions [9] (Ma and Safikhani 2022), for Lipschitz losses under strong mixing (Kengne and Wade, 2025), and for generalized Bayes estimators on Markov chains with a spectral gap [2]. For a likelihood loss, Yara and Terada [20] obtain Hellinger rates for nonparametric maximum likelihood over deep networks from independent replications of a covariate-driven Poisson process. These results do not cover deep count forecasting. The loss there is a likelihood for unbounded and overdispersed responses, with a second unknown function for the dispersion; the covariates are generated by the process itself, along a single trajectory that need be neither stationary nor mixing; and translating estimation error into count-valued predictive distributions several steps ahead requires an additional argument. Deriving mixing from model assumptions, as we do for the out-of-sample risk, is not unique to the present work [9 Lemma 4.1].

A second line of work, in statistics, models the conditional mean of a count given the past with a parametric form. Poisson and negative binomial autoregressions have a well-developed theory [4] (Neumann 2011; Davis et al. 2016), nonparametric autoregression is classical for continuous responses (Fan and Yao, 2003), and the endemic–epidemic framework of Held et al. (2005) and Meyer and Held (2014) adds spatial spillover between regions and is the standard tool of surveillance epidemiology. Recent parametric developments include parsimonious spatio-temporal count autoregressions with consistent and asymptotically normal quasi-likelihood estimators [10] and negative binomial models whose dispersion follows its own observation-driven recursion [14]. Bayesian hierarchical models add zero inflation and spatial and temporal random effects with Gaussian process priors, with posterior computation by Pólya–Gamma data augmentation [6, 13] (Polson et al. 2013; Huang and He 2024), and shrinkage priors extend Bayesian count regression to sparse variable selection for mixed-type multivariate responses (Wang et al., 2025). These models are interpretable and their properties are understood, but a mean that is log-linear in the covariates cannot express thresholds, saturation, or interactions between the level of a site and that of its neighbors. Nonparametric theory for count autoregression is scarce: Wechsung and Neumann [17] obtain a rate for a least squares estimator of the contractive link function of a univariate Poisson autoregression. Neural networks have entered count modeling in two other ways, neither with a rate theory. They serve as the response function of an integer-valued autoregression, a small network fitted as a parametric model [8]; and they serve as amortized estimators: Svensson [15] pre-trains a transformer on simulated data to return the three parameters of a two-group negative binomial regression with independent observations, and reports that closed-form moment estimators are the most efficient solution of that task. There the network replaces the optimizer, while the model stays parametric and the data independent. Here the network is the nonparametric component of the model, and the object of study is the conditional law of a dependent panel.

In this work, we study a model that connects these two lines and admits a statistical analysis under explicit restrictions. The deep negative binomial spatio-temporal autoregression, DeepNB-STAR, specifies that the count Ys,tY_{s,t} at site ss in week tt is, given the past, negative binomial with mean exp⁡{f0(Xs,t)}\exp\{f_0(X_{s,t})\} and size exp⁡{g0(Xs,t)}\exp\{g_0(X_{s,t})\}, where the covariate vector Xs,tX_{s,t} summarizes the recent counts of the site, those of its nearest neighbors, the overall level and the season, and f0f_0 and g0g_0 are unknown functions. Temporal dependence and spatial dependence enter through the arguments of both functions, and sparsity and overdispersion are handled by the likelihood. We estimate f0f_0 and g0g_0 jointly by maximum likelihood over deep ReLU networks with two outputs and obtain the predictive distribution at any horizon by simulating the fitted model forward. The network is not the contribution: it is the sieve that lets a likelihood model with two unknown functions of several dozen lagged and neighboring summaries adapt to low-dimensional structure. The contribution is statistical. It consists of a nonparametric count autoregression in which the overdispersion, like the mean, is an unknown function of the spatio-temporal past; of a theory for it that takes one dependent trajectory as it is, with a lower bound; and of guarantees for the object used in practice, the multi-step predictive distribution and its intervals. Because the model specifies the joint law of the panel, the questions raised above have precise answers.

Our main results are as follows. An oracle inequality bounds the Hellinger risk of the maximum likelihood estimator along the observed trajectory by the approximation error of the network class plus its metric entropy divided by the sample size. It requires only that the conditional model be correctly specified; no stationarity or mixing is assumed, so it applies to the autoregressive, spatially coupled and seasonal panel as it is. Conditional independence across sites, which the model also specifies, is not needed: if only the conditional law of each count is correct, the same inequality holds with the number of periods TT in place of n=STn = ST in its stochastic term, and this cannot be improved in general. When f0f_0 is a composition of Hölder functions, each depending on few variables, the inequality yields, up to logarithmic factors, the rate ϕn\phi_n that Schmidt-Hieber [12] obtained for least squares regression with independent Gaussian errors, defined in (5). For a Hölder subclass, we prove a matching lower bound, for any number of sites, in an experiment whose covariates include exogenous inputs; it does not cover a covariate map that depends on past counts alone, which we discuss. A model with bounded log-mean and finite memory, possibly driven by independent exogenous inputs, is shown to be geometrically absolutely regular (Bradley, 2005), which yields the risk on an independent copy of the process. We then bound the total variation distance between the fitted and the true predictive distributions, one step and hh steps ahead, by the estimation risk plus the Monte Carlo error of the simulated quantities; this gives explicit bounds on the difference between the fitted and the true coverage probabilities of prediction intervals at every horizon. Finally, all these results extend to a size that is unknown and may depend on the covariates, estimated jointly with the log-mean as a second output of the network. Averages of several fits inherit the rates, and so do functionals of the two functions that are Lipschitz in the empirical norm, such as averages over the observed site-weeks; this motivates the exploratory bootstrap summaries we report but does not validate their intervals, and functionals that evaluate the functions at unobserved covariate values, such as partial effects, are not covered.

The proofs combine known devices with new steps, and we separate the two. The conditional expectation of the square root of a likelihood ratio equals one minus the squared Hellinger distance, so an exponential supermartingale inequality bounds the Hellinger risk at the covariate values actually visited. This argument goes back to maximum likelihood for counting processes [16] and is used for sequential density estimation [21, 1]. For the horizon, the simulation lemma of reinforcement learning adds one-step total variation errors, so the bound grows linearly (Kearns and Singh, 2002; Munos and Szepesvári, 2008), whereas Kullback–Leibler divergences are additive by the chain rule; trajectory-level analyses of the logarithmic loss exist for independent trajectories, in Hellinger distance [5] and in Kullback–Leibler divergence under bounded log-density ratios [19]. The error of the hh-step predictive law is then of order h1/2h^{1/2} times the root of the one-step risk. What is new is the analysis of a single trajectory of unbounded counts over a sieve: the unbounded likelihood ratio is controlled through conditional moment generating functions of the negative binomial law, which keeps the fast rate; the size is a second unknown function, separated from the mean in Hellinger distance through the first two factorial moments; a generalized Hölder inequality replaces conditional independence across sites in the supermartingale; and the rates are tied to the coverage of simulated prediction intervals, under the stated restrictions on the estimator and on the evaluation law (§ 6).

We complement the theory with experiments. In simulations with a known log-mean, the risks of the practical fit and of a fit that satisfies the constraints of the theory both decrease at least at the guaranteed rate, trajectory and out-of-sample risks are close, and the error of predictive distributions decreases with the estimation error; when the size depends on the covariates, both functions are estimated at the guaranteed rate and moving-block bootstrap standard errors are close to the sampling standard deviations, although intervals built from them undercover where the estimator is biased. We then forecast weekly notifications of four diseases in the 47 prefectures of Japan from 1999 to 2024: syphilis, whose annual notifications rose about seventeen-fold from 2012 to 2024 (Takahashi et al., 2018); enterohemorrhagic E. coli infection, a stable and strongly seasonal series; legionellosis, a sparse and rising panel; and amebiasis, a sparser and declining panel. The estimator was developed on syphilis and tested on new panels under protocols written before any model was fitted to them; amebiasis, chosen by a fixed rule, is the test panel of the final protocol. On all four panels DeepNB-STAR has a lower weighted interval score than an ensemble of three Temporal Fusion Transformers, by 0.6% to 1.0%; on amebiasis the difference, 0.9%, is distinguishable from zero, on the other panels it is not, and in one period of one panel the transformer is better. DeepNB-STAR is clearly better than DeepAR and persistence, and better than or on a par with negative binomial regression and a Bayesian ZINB-GP model [6]. Because DeepNB-STAR is a likelihood model, its fit also describes the fitted mean and size functions, with exploratory point-wise bootstrap intervals: for instance, the fitted association with neighboring prefectures is strongest where the local level is low. On daily taxi-flow networks, a second domain in the supplement, the gain over a log-linear autoregression is 7.5%.

Section 2 sets up the model, the covariates and the function class; Section 3 summarizes the main results; Section 4 gives the estimator, the forecasting algorithm and the inference procedure; Section 5 states the results and Section 6 outlines their proofs, which are in the appendix; Sections 7 and 8 report simulations and the application, and Section 9 concludes.

Notations. Sites are indexed by s=1,…,Ss = 1,\ldots,S and weeks by t=1,…,Tt = 1,\ldots,T, and n=STn = ST is the number of site-weeks. We write NB⁡(μ,r)\operatorname{NB}(\mu,r) for the negative binomial distribution with mean μ>0\mu> 0 and size r>0r > 0, whose probability mass function is

p(y)=Γ(y+r)Γ(r)y!(rr+μ)r(μr+μ)y,y=0,1,2,…,p(y) = \frac{\Gamma(y+r)}{\Gamma(r)y!}\left(\frac{r}{r+\mu}\right)^r\left(\frac{\mu}{r+\mu}\right)^y,\qquad y = 0,1,2,\ldots,

with Γ\Gamma the gamma function; its variance is μ+μ2/r\mu+ \mu^2/r. We write pfp_f for this mass function when μ=ef\mu=e^f, and call ff the log-mean. For probability mass functions pp and qq on the non-negative integers, H2(p,q)=1−∑y{p(y)q(y)}1/2H^2(p,q)=1-\sum_y\{p(y)q(y)\}^{1/2} is the squared Hellinger distance, TV⁡(p,q)=12∑y∣p(y)−q(y)∣\operatorname{TV}(p,q)=\frac{1}{2}\sum_y|p(y)-q(y)| the total variation distance and KL⁡(p∥q)=∑yp(y)log⁡{p(y)/q(y)}\operatorname{KL}(p\mathbin\Vert q)=\sum_y p(y)\log\{p(y)/q(y)\} the Kullback–Leibler divergence; these satisfy TV⁡≤2H\operatorname{TV}\le\sqrt{2}H and Pinsker’s inequality TV⁡≤(KL⁡/2)1/2\operatorname{TV}\le(\operatorname{KL}/2)^{1/2} (Tsybakov, 2009, Section 2.4). The same symbols are used for probability measures on general spaces. ∥g∥∞\|g\|_\infty denotes the supremum norm of a function gg on its domain, ∥g∥L2\|g\|_{L^2} its L2L^2 norm with respect to Lebesgue measure on [0,1]d[0,1]^d, and ∣u∣∞|u|_\infty the maximum norm of a vector uu. All logarithms are natural except log⁡2\log_2. We write a∧b=min⁡(a,b)a\wedge b=\min(a,b), a∨b=max⁡(a,b)a\vee b=\max(a,b) and u+=max⁡(u,0)u_+=\max(u,0); ⌊x⌋\lfloor x\rfloor and ⌈x⌉\lceil x\rceil are the integer part and the smallest integer not less than xx, except that for a smoothness index β>0\beta>0 we follow Schmidt-Hieber [12] and let ⌊β⌋\lfloor\beta\rfloor denote the largest integer strictly smaller than β\beta. For a multi-index α=(α1,…,αk)\alpha=(\alpha_1,\ldots,\alpha_k) of non-negative integers, ∣α∣=∑jαj|\alpha|=\sum_j\alpha_j and ∂α=∂1α1⋯∂kαk\partial^\alpha=\partial_1^{\alpha_1}\cdots\partial_k^{\alpha_k}.

a≲ba\lesssim b indicates that a≤cba\le cb for a constant c>0c>0 that does not depend on the sample size, and a≍ba\asymp b that a≲ba\lesssim b and b≲ab\lesssim a. 1{E}\mathbf{1}\{E\} is the indicator of the event EE, E\mathbb{E} denotes expectation, and Ef\mathbb{E}_f expectation when the panel follows the model with log-mean function ff. Constants denoted by CC and cc may change from line to line. For the function class and the networks we keep the notation of Schmidt-Hieber [12], in which dd, tt, pp and βi\beta_i are unrelated to the covariate dimension dd, the week tt, the mass function pfp_f and the mixing coefficients βX(⋅)\beta_X(\cdot).

Problem Setup

We first introduce the model, then the covariates that encode temporal and spatial dependence, and finally the class of target functions.

Deep Negative Binomial Spatio-Temporal Autoregression

Let Ys,t∈{0,1,2,…}Y_{s,t}\in\{0,1,2,\ldots\} be the count at site s∈{1,…,S}s\in\{1,\ldots,S\} in week t∈{1,…,T}t\in\{1,\ldots,T\}, Yt=(Y1,t,…,YS,t)Y_t=(Y_{1,t},\ldots,Y_{S,t}), and let It\mathcal{I}_t be the σ\sigma-field generated by YuY_u, u≤tu\le t, together with any covariates known by the start of week t+1t+1. The model has two ingredients. The first is a covariate map: for each site and week,

Xs,t=Φs(Yt−1,…,Yt−m;t)∈[0,1]d(1)X_{s,t}=\Phi_s(Y_{t-1},\ldots,Y_{t-m};t)\in[0,1]^d \tag*{(1)}

is a vector of dd summaries of the last mm weeks, computed by a known measurable map Φs\Phi_s; we call mm the memory of the model. Independent exogenous inputs can be added as further arguments of Φs\Phi_s (Assumption 4). The second is a pair of functions, the log-mean f0:[0,1]d→[−F,F]f_0:[0,1]^d\to[-F,F] and the log-size g0:[0,1]d→[γlo,γhi]g_0:[0,1]^d\to[\gamma_{\mathrm{lo}},\gamma_{\mathrm{hi}}]. DeepNB-STAR specifies that, given It−1\mathcal{I}_{t-1},

Ys,t∣It−1∼NB⁡(exp⁡{f0(Xs,t)},exp⁡{g0(Xs,t)})independently for s=1,…,S,(2)Y_{s,t}\mid\mathcal{I}_{t-1}\sim\operatorname{NB}\bigl(\exp\{f_0(X_{s,t})\},\exp\{g_0(X_{s,t})\}\bigr)\quad\text{independently for }s=1,\ldots,S, \tag*{(2)}

so that E(Ys,t∣It−1)=μs,t=ef0(Xs,t)\mathbb{E}(Y_{s,t}\mid\mathcal{I}_{t-1})=\mu_{s,t}=e^{f_0(X_{s,t})} and var⁡(Ys,t∣It−1)=μs,t+μs,t2e−g0(Xs,t)\operatorname{var}(Y_{s,t}\mid\mathcal{I}_{t-1})=\mu_{s,t}+\mu_{s,t}^2e^{-g_0(X_{s,t})}: the size eg0e^{g_0} controls the overdispersion, which can thus vary with the local level, the neighbors and the season. The special case of a constant size rr,

Ys,t∣It−1∼NB⁡(exp⁡{f0(Xs,t)},r)independently for s=1,…,S,(3)Y_{s,t}\mid\mathcal{I}_{t-1}\sim\operatorname{NB}\bigl(\exp\{f_0(X_{s,t})\},r\bigr)\quad\text{independently for }s=1,\ldots,S, \tag*{(3)}

References

  1. [1]Alekh Agarwal, Sham Kakade, Akshay Krishnamurthy, and Wen Sun. FLAMBE: Structural complexity and representation learning of low rank MDPs. In Advances in Neural Information Processing Systems, volume 33, 2020.arxiv.org/abs/2006.10814
  2. [2]Pierre Alquier and William Kengne. Minimax optimality of deep neural networks on dependent data via PAC-Bayes bounds, 2025. arXiv:2410.21702, version 2.arxiv.org/abs/2410.21702
  3. [3]Abhirup Datta, Sudipto Banerjee, Andrew O. Finley, and Alan E. Gelfand. Hierarchical nearest-neighbor Gaussian process models for large geostatistical datasets. Journal of the American Statistical Association, 111(514):800–812, 2016.DOI
  4. [4]Konstantinos Fokianos, Anders Rahbek, and Dag Tjøstheim. Poisson autoregression. Journal of the American Statistical Association, 104(488):1430–1439, 2009.DOI
  5. [5]Dylan J. Foster, Adam Block, and Dipendra Misra. Is behavior cloning all you need? Understanding horizon in imitation learning. In Advances in Neural Information Processing Systems, volume 37, 2024.arxiv.org/abs/2407.15007
  6. [6]Qing He and Hsin-Hsiung Huang. A framework of zero-inflated Bayesian negative binomial regression models for spatiotemporal data. Journal of Statistical Planning and Inference, 229:106098, 2024.DOI
  7. [7]Su I Iao, Yidong Zhou, and Hans-Georg Müller. Deep Fréchet regression. Journal of the American Statistical Association, 120(551):1437–1448, 2025.
  8. [8]Malte Jahn. Artificial neural networks and time series of counts: A class of nonlinear INGARCH models. Studies in Nonlinear Dynamics & Econometrics, 28(5):751–765, 2024.arxiv.org/abs/2304.01025
  9. [9]Daisuke Kurisu, Riku Fukami, and Yuta Koike. Adaptive deep learning for nonlinear time series models. Bernoulli, 31(1):240–270, 2025.arxiv.org/abs/2207.02546
  10. [10]Steffen Maletz, Konstantinos Fokianos, and Roland Fried. Spatio-temporal count autoregression. Data Science in Science, 3(1):2425171, 2024.DOI
  11. [11]Alexander Petersen and Hans-Georg Müller. Fréchet regression for random objects with Euclidean predictors. The Annals of Statistics, 47(2):691–719, 2019.arxiv.org/abs/1608.03012
  12. [12]Johannes Schmidt-Hieber. Nonparametric regression using deep neural networks with ReLU activation function. The Annals of Statistics, 48(4):1875–1897, 2020.
  13. [13]Mahlon Scott, Qing He, and Hsin-Hsiung Huang. ZINB.GP: Bayesian Zero-Inflated Negative Binomial Gaussian Process Models, 2026. URL https://CRAN.R-project.org/package=ZINB.GP. R package version 1.0.0.DOI
  14. [14]Rodrigo B. Silva, Luiza S. C. Piancastelli, and Wagner Barreto-Souza. A spatiotemporal negative binomial model with dynamic dispersion: An application to tuberculosis infections, 2026. arXiv:2609.10174.arxiv.org/abs/2609.10174
  15. [15]Valentine Svensson. Negative binomial regression and inference using a pre-trained transformer, 2025. arXiv:2508.04111.arxiv.org/abs/2508.04111
  16. [16]Sara van de Geer. Exponential inequalities for martingales, with application to maximum likelihood estimation for counting processes. The Annals of Statistics, 23(5):1779–1801, 1995.DOI
  17. [17]Maximilian Wechsung and Michael H. Neumann. Consistency of a nonparametric least squares estimator in integer-valued GARCH models. Journal of Nonparametric Statistics, 34(2):491–519, 2022.arxiv.org/abs/2009.10383
  18. [18]Luhuan Wu, Geoff Pleiss, and John P. Cunningham. Variational nearest neighbor Gaussian process. In Proceedings of the 39th International Conference on Machine Learning, volume 162 of Proceedings of Machine Learning Research, pages 24114–24130, 2022.arxiv.org/abs/2202.01694
  19. [19]Yunbei Xu, Yuzhe Yuan, and Ruohan Zhan. Autoregressive learning in joint KL: Sharp oracle bounds and lower bounds, 2026. arXiv:2605.12316.arxiv.org/abs/2605.12316
  20. [20]Atsutomo Yara and Yoshikazu Terada. Nonparametric intensity estimation for covariate-driven Poisson processes using deep learning, 2026. arXiv:2611.03552.arxiv.org/abs/2611.03552
  21. [21]Tong Zhang. From ε-entropy to KL-entropy: Analysis of minimum information complexity density estimation. The Annals of Statistics, 34(5):2180–2210, 2006.DOI

Paper details

vlnc:W_76zagxeq
Version
v1 · latest
Published
Fresh — added to the Hub within the last 30 days
Added
License
CC BY 4.0
Usage

views · 2

downloads · 0

A view counts once per browser per day, a download each time the PDF is requested.

  • Mathematics

Not recorded for this paper

View statement
Looking for related papers…
Contents