7
$\begingroup$

Direct Question: Are there any measures of auto-correlation for a sequence of observations of an (unordered) categorical variable?

Background: I'm using MCMC to sample from a categorical variable and I'd like a measure of how well the sampling method I've developed is mixing across the posterior distribution. I'm familiar with acf plots and auto-correlation for continuous variables, but I've been stuck looking at the transition probability matrix for this categorical variable... Any thoughts?

$\endgroup$
  • $\begingroup$ You are sampling to get the posterior distribution of the variable, right? Maybe I'm missing something here, but it doesn't matter if the variable is categorical or not, since the autocorrelation of the MCMC gives to you how fast it will sample the whole space of the distribution, right? Btw, are you using it in regression? $\endgroup$ – Manoel Galdino May 14 '11 at 13:23
6
$\begingroup$

You can always choose one or several real valued functions of the categorical variables and look at the auto-correlation for the resulting sequence(s). You can, for instance, consider indicators of some subsets of the variables.

However, if I understood your question correctly, your sequence is obtained by an MCMC algorithm on the discrete space. In that case, it may be more interesting to look directly at the convergence rate for the Markov chain. Chapter 6 in this book by Brémaud treats this in details. The size of the second largest absolute value of the eigenvalues determines the convergence rate of the matrix of transition probabilities and thus the mixing of the process.

$\endgroup$
0
$\begingroup$

Instead of computing acf on your simulated time series, you could first create a time series of number of each kind of state change per unit of time (so you will a time serie for each state). And then compute the acf on each of the time series, and compare it with the real ones. It's not a direct method, but you still you'll know if the rate of each kind of state changes through time is respected.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.