How to Measure Segregation