# Estimation the evolution of error variance with time?

I have data tuples $$(x_i,\varepsilon_i,t_i)$$ generated from some observations and I suspect that $$\varepsilon \sim \mathcal{N}\left(0,\sigma(t)^2\right)$$, where $$\sigma(t)$$ is an increasing function of time, i.e. the data is zero-mean but clearly manifests increasing variance as time progresses.

The first approach is to bin the data and estimate the distribution of each bin, but the spacing of the data is not uniform in $$t$$ and so some bins have large populations and others are empty, plus the choice of bin size in arbitrary and I'd prefer something that uses the time series more naturally.

I want to know how to

1) infer the functional form of $$\sigma(t)$$. To start I assume $$\sigma(t)^2 =\sigma_1^2 + \sigma_2^2 t$$ and want to estimate $$\sigma_1$$,$$\sigma_2$$ from observations

2) assess the relative agreement between the proposed distribution and the observations

My approach is now to try something like $$p(\varepsilon_i \vert \boldsymbol{\theta},t_i) = \frac{1}{\sqrt{2\pi \left(\theta_1^2 + \theta_2^2t \right)}}\exp\left[\frac{-\varepsilon^2}{2\left(\theta_1^2 + \theta_2^2t \right)}\right]$$ and put some prior on $$\boldsymbol{\theta}$$ and do regular inference basically treating samples as independent (conditioned on $$t$$). I can then use general tests of agreement with distributions to assess goodness of fit. My worry is that I am not treating the time parameter correctly.

I'd be very interested in any comments, any references or other ways of casting this problem.

Fit a random effect model to $$\epsilon$$:
$$\epsilon = \gamma \sqrt t + \epsilon_e$$ with assumption that $$\gamma \sim N(0,\sigma_2^2)$$ and $$\epsilon_e \sim N(0,\sigma_1^2)$$, $$\gamma$$ and $$\epsilon_e$$ are independent. Then $$\epsilon \sim N(0,\sigma_1^2 + t \sigma_2^2)$$. Obsessively, you will get the estimate of $$\sigma$$s from this model and use general tests of agreement with distributions to assess goodness of fit.