They didn't develop in China
They did.
the most large or profitable economic activities were already under direct government monopoly.
This would be quite strange if it were true, because late imperial China's official : population ration was very low. Well, it's not true. The government had no monopoly on cotton, nor on tobacco, nor on sugar, nor on timber, nor on manufactured goods, nor on basic agricultural products (rice, etc)... The virtually only monopoly the High Qing state had was on salt, and even that was shaky due to widespread smuggling.
Until the 20th century China was almost entirely small family businesses or government monopolies with very little of the midsized economic activity that drove joint stock creation in Europe.
So the Huizhou or Shanxi merchant guilds were "small family businesses"? Yes, Huizhou merchant guilds were primarily composed of merchants from Huizhou, but that doesn't make it a family business because by Qing times such guilds were inclusive of at the very least most merchants from the Huizhou region regardless of familiar ties. And as time went on this regional base weakened and guilds became more professionally commercial. Besides, Chinese businesses should not be generalized as small - by the early 19th century, Shanxi lumber firms regularly employed thousands of wage workers, making them one of the largest firms in the preindustrial world. It is also worth noting that family firms were very much European as well around this time.
China had little economic competition
Little economic competition when the city of Suzhou alone had forty guilds competing for business? And logically, how could there have been little competition given the Qing state's
laissez-faire attitude towards the economy and the sheer size of China?
Why didn't they develop elsewhere, especially in China
There were. Japanese historian Imahori Seiji believes there was a "primitive form of joint-stock company" as early as the tenth century, and William Rowe has shown there were joint-stock companies in Hankou by the 19th century per
Hankow: Conflict and Community in a Chinese City, 1796-1895. Some people disagree with his assessment for large firms (which they think is more like modern Chinese firms' parent-subsidiary relationships) but smaller firms definitely look like the "classic type" of joint-stock firms, to quote Rowe. Other scholars have found joint-stock elsewhere, like Madeleine Zelin in the salt industry. Chinese joint-stock firms aren't as developed or coherently organized as British joint-stock firms, to be sure, but like most supposedly unique European things it's just a matter of degree.
But on a more fundamental level, a lot of the famous joint-stock companies originate from long-distance trade firms. China lacked this dynamic, not because it didn't trade (of course it did!) but because of the monsoon system. Chinese ships found it very difficult to move against the monsoon compared to Dutch or British ships, so, to quote Kenneth Pomeranz, "a group of land-based entrepreneurs who used all the cargo space themselves or rented it for cash would have found themselves paying enormous wage to support professional sailors during long stays on shore [waiting for the monsoon to reverse]. It made more sense to make many shorter stops and have crewmembers who could and did occupy themselves in buying and selling cargo at each port." Companies like the ones that participated in overland trade with Russia looked significantly more like European firms.