Quantcast
Channel: Statalist
Viewing all articles
Browse latest Browse all 72776

How tabstat handles missing zero-observation combinations

$
0
0
I'm tabulating some descriptive statistics by country with tabstat, using something like
Code:
tabstat money_var if condition_var == X, by(country) stat(sum)
It seems that when the if condition is not met for a given country, then the matrix of sums is shortened, eliminating the entry for that country. What I need is to keep the country and put a zero in the corresponding row of the sum matrix. Is it possible?

Viewing all articles
Browse latest Browse all 72776

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>