> Whether because they don’t adequately treat the condition they’re meant to target or the side effects are too strong, many drug candidates never advance to the approval stage.
And that doesn't sound "successful" at all. How much money is sunk into R&D at the point of failure is the much more relevant statistic to consider. If the pharmaceutical industry wasn't wildly profitable, they'd be investing those billions elsewhere, leaving drugs to a slow-cooking niche.
If you are interested in the topic, for example for oncology: https://jamanetwork.com/journals/jamanetworkopen/fullarticle... , to quote "Failed drug development in oncology incurs substantial expense. At an industry level, an estimated $50 billion to $60 billion is spent annually on failed oncology trials."
There is no "oracle" that says invest 50 million (or 100 million or 1 billion) in X or Y and it will succeed (in pharma or other domains). And this is not exclusively because of capitalism, it is because doing some things is hard.
When I hear "{x} is not very profitable" I think people mean "we are not sure if we succeed doing {x} and it requires us to divert lots of resources from other things that we think would be more useful".
Pharma companies invest already huge amounts in drugs and many fail anyhow. Quote: "It takes 10 to 15 years and around US$1 billion to develop one successful drug. Despite these significant investments in time and money, 90% of drug candidates in clinical trials fail." (https://www.asbmb.org/asbmb-today/opinions/031222/90-of-drug...)