Analysis of categorical data