  In 2009, Grant, Shallit, and Stoll constructed a large family of pseudorandom
sequences, called generalized Rudin--Shapiro sequences, for which they
established some results about the average of discrete correlation coefficients
of order 2 in cases where the size of the alphabet is a prime number or a
squarefree product of primes. We establish similar results for an even larger
family of pseudorandom sequences, constructed via difference matrices, in the
case of an alphabet of any size. The constructions generalize those from Grant
et al. In the case where the size of the alphabet is squarefree and where there
are at least two prime factors, we obtain an improvement in the error term by
comparison with the result of Grant et al.
