We develop a new statistical method for inferring phylogenies, based on a likelihood ratio test. This method does not require parameter constraints but does require identical evolutionary processes in the sites considered. Another method of phylogenetic inference is the method of linear invariants, described by Cavender (1989, Molecular Biology and Evolution 6, 301-316), based on a notion of Lake (1987, Molecular Biology and Evolution 4, 167-191). We describe a sound mathematical basis for the use of linear invariants. We show that the validity of the method requires parameter constraints, but does not require that the evolutionary processes in differing sites be identical. We show that the method of linear invariants is asymptotically equivalent to a less powerful version of our likelihood ratio test, and is thus essentially a maximum likelihood technique.