Regression analysis of grouped counts and frequencies using the generalized linear model