(CNN) A new survey in Colorado suggests that more than one-third of homeless jail inmates who have come to the state since 2012 have come, at least in part, because of legal marijuana.

But the survey, commissioned by the Colorado Division of Criminal Justice, is getting mixed reviews: from a sheriff who says the results are no surprise, to a marijuana lobbyist who called it "irrelevant."

The survey of 507 mostly homeless inmates housed in seven city and county jails was aiming to shed light on the claim made largely by law enforcement: that legal marijuana is attracting transient homeless people to Colorado.

But the head of the agency that commissioned the study said it hardly puts the question to rest. It found that of the homeless inmates sampled, most had come to Colorado before legalization. The rest, about 41%, came after 2012, when Colorado voted to legalize recreational marijuana. Of the sample, 77 inmates fit that description, or roughly 1% of the total population of the jails that were surveyed. Thirty-five percent of those inmates said legal marijuana was among the reasons they came to Colorado.

"That's not insignificant," said Stan Hilkey, the executive director of Colorado's Department of Public Safety. "We know that marijuana is one of the reasons that it's drawn some of the people here since legalization. It's not the top reason, but remains one of the reasons."

Read More