There seems to be an alternative to the chisquared test, in place of $\sum (O-E)^2/E$, just do $\sum (O-E)^2$, this is asked about at
stats.stackexchange.com/questions/605760/…. I once found a paper about this, but cannot find it again now. Anybody knows?