```python

obs_freqs = numpy.mean(data, axis=1)
n = obs_freqs.sum()
```