Malaysia's Mahathir Mohamad towered over his country's politics for more than two decades.
Mahathir Mohamad dominated Malaysia for two decades
While his colourful reputation abroad stemmed from frequent barbed comments about the West and his scant regard for human rights, his authoritarian but essentially pragmatic policies at home won him much popular support and helped transform Malaysia into an Asian economic tiger.
During the process he turned himself into one of Asia's longest-serving leader, and when he retired in October he had been in office for 22 years.
Throughout his rule Dr Mahathir, 77, took a tough stand against those who opposed him or threatened his power.
Anwar Ibrahim, once his deputy and heir apparent, is still serving a jail sentence he began in 1998 after the prime minister abruptly dismissed him from his cabinet post and accused him of sodomy and corruption.
More recently, Dr Mahathir was accused of using the US-led war on terrorism as an excuse to neutralise Islamic political opponents at home.
Scores of suspected militants have been arrested without trial under the much-criticised Internal Security Act.
In the immediate aftermath of the September 11 attacks Dr Mahathir offered his full support and cooperation to the United States and projected himself as a moderate spokesman for the Muslim world.
But he was furious when he himself was subjected to rigorous security checks at a US airport. He said American "anti-Muslim hysteria" had led to him being treated like a terrorist.
And he said the attacks on Afghanistan and then Iraq could degenerate into a campaign against the developing world as a whole.
Since Dr Mahathir became prime minister in 1981, government patronage and positive ethnic discrimination in employment and higher education have created a Malay middle class, including some billionaires.
But the ethnic Chinese minority is still seen as having disproportionate wealth, and the prime minister has frequently accused his fellow Malays (or Bumiputras - "sons of the soil") of being complacent and unwilling to work hard.
"I feel disappointed", Dr Mahathir said before he stepped down, "because I have achieved too little in my principal task of making my race a successful race, a race that is respected."
Mahathir Mohamad's political career began in 1946, when at the age of 21 he joined the newly founded nationalist organisation United Malays National Organisation (Umno).
He studied medicine at the University of Malaya and for seven years ran a private medical practice in his home state of Kedah.
"Dr M", as he is popularly known, became an Umno member of parliament in 1964.
But in 1969 he lost his seat and was expelled from the party after releasing an open letter attacking the then Prime Minister, Tunku Abdul Rahman, for neglecting the Malay community.
Exiled to the political wilderness, he developed his ideas in a controversial book entitled The Malay Dilemma.
Malaysia was transformed under Dr Mahathir's rule
He wrote that the Malays had been marginalised during the colonial era and castigated them for apathetically accepting their second-class status.
It set the tone for future attacks on Western neo-colonialists and others he sees as bent on subjugating Malaysia and threatening its success.
The Malay Dilemma struck such a chord with younger Umno leaders that he was invited back into the party, re-elected to parliament in 1974, and appointed minister of education.
Within four years he had become deputy leader of Umno, and in 1981 he became prime minister.
Dr Mahathir set about putting his ideas into practice, following the example set by Japan, transforming Malaysia from an exporter of rubber and tin into a manufacturer of electronic equipment, steel and cars.
Defending Asian and Malaysian values, he criticised what he called Western double standards and won a following among developing countries.
His prestige projects to boost national pride included the world's tallest building - the Petronas Towers - and the transformation of a palm oil plantation near the capital into the world's first "Multimedia Super Corridor" - a cyber powerhouse intended to rival California's Silicon Valley.
With the onset of the Asian economic crisis in 1997, Dr Mahathir refused to accept that his grandiose schemes were partly to blame for Malaysia's massive debt. Instead he blamed foreign currency traders, including the financier George Soros, for what he termed a worldwide Jewish conspiracy.
Malaysia emerged relatively unscathed from the Asian financial crisis after Dr Mahathir defied the International Monetary Fund, introducing controversial currency controls which effectively isolated his country from the global economy.
But relations with the West have continued to fluctuate. In June this year Dr Mahathir described Westerners - or more particularly "Anglo-Saxon Europeans" -- as proponents of "war, sodomy and genocide".
Days before he resigned, he angered several foreign governments and Jewish groups by claiming the a Jewish cabal "ruled the world".