The bill, introduced earlier this month, proposes tough new penalties for same-sex relations in a country where homosexuality is already illegal, sparking criticism from human rights groups.
In a state of the nation address before lawmakers, Museveni, who has ruled Uganda since 1986, called gay people deviants as MPs urged him to comment on the new legislation.
"The homosexuals are deviations from normal. Why? Is it by nature or nurture. We need to answer these questions," the 78-year-old said.
"We need a medical opinion on that. We shall discuss it thoroughly."
Under the proposed law, anyone who engages in same-sex activity or who identifies as LGBTQ could face up to 10 years' imprisonment.
The bill comes as conspiracy theories accusing shadowy international forces of promoting homosexuality gain traction on social media in Uganda.
"Western countries should stop wasting the time of humanity by trying to impose their practices on other people," Museveni said in an address boycotted by all but one opposition legislator.
"Europeans and other groups marry cousins and near relatives. Here, marrying in one's clan is taboo. Should we impose sanctions on them for marrying relatives? This is not our job," he added.
The bill is due to be discussed next week, with a vote possible as early as Tuesday.
Uganda is notorious for intolerance of homosexuality - which is criminalized under colonial-era laws - and strict Christian views on sexuality in general.
But since independence from Britain in 1962 there has never been a conviction for consensual same-sex activity.
In 2014 Ugandan lawmakers passed a bill that called for life in prison for people caught having gay sex.
A court later struck down the law on a technicality, but it had already sparked international condemnation, some Western nations freezing or redirecting millions of dollars of government aid in response.
KAMPALA - Uganda's President Yoweri Museveni on Thursday described gay people as "deviants" and called for an investigation into homosexuality as lawmakers in the conservative East African nation prepare to vote on an anti-LGBT bill.