Assessing the validity of autologistic regression