In ruling Michigan's gay marriage ban invalid, U.S. District Court Judge Bernard Friedman called the testimony of the state's prime witness “unbelievable.”

Friedman on Friday handed down his 31-page ruling following a two-week trial that ended on March 7.

(Related: Michigan's ban on gay marriage struck down.)

Mark Regnerus, an associate professor of sociology at the University of Texas at Austin, testified on behalf of the state for more than three hours.

Regnerus is the lead author of a widely criticized 2012 study which concluded that children are negatively affected by having gay parents. The study was funded by the socially conservative New Jersey-based Witherspoon Institute.

Friedman found neither the study nor its author to be credible.

“The Court finds Regnerus’s testimony entirely unbelievable and not worthy of serious consideration,” Friedman wrote. “The evidence adduced at trial demonstrated that his 2012 'study' was hastily concocted at the behest of a third-party funder, which found it 'essential that the necessary data be gathered to settle the question in the forum of public debate about what kinds of family arrangement are best for society' and which 'was confident that the traditional understanding of marriage will be vindicated by this study.' While Regnerus maintained that the funding source did not affect his impartiality as a researcher, the Court finds this testimony unbelievable. The funder clearly wanted a certain result, and Regnerus obliged.”

“Whatever Regnerus may have found in this 'study,' he certainly cannot purport to have undertaken a scholarly research effort to compare the outcomes of children raised by same-sex couples with those of children raised by heterosexual couples. It is no wonder that the NFSS has been widely and severely criticized by other scholars, and that Regnerus’s own sociology department at the University of Texas has distanced itself from the NFSS in particular and Dr. Regnerus’s views in general.”