SpaceX and Tesla Chief Executive Officer Elon Musk on Wednesday apologised for calling British cave diver Vernon Unsworth “a pedo”. Unsworth was instrumental in saving the lives of 12 schoolboys and their football coach who were marooned in a cave in Thailand for over 10 days.

“My words were spoken in anger after Mr Unsworth said several untruths and suggested I engage in a sexual act with the mini-sub, which had been built as an act of kindness and according to specifications from the dive team leader,” Musk said. “Nonetheless, his actions against me do not justify my actions against him, and for that I apologize to Mr Unsworth and to the companies I represent as leader. The fault is mine and mine alone.”

The businessman had got his team to build a mini-submarine to help with the rescue. But the contraption, which was brought to Thailand, was not used during the mission. Unsworth had later said that the mini-submarine was not practical and that the move was a “publicity stunt” by Musk. On Sunday, a miffed Musk launched a scathing attack on Unsworth. In a series of now-deleted tweets, he said he would release video footage of one of the mini-submarines easily navigating one of the caves.

Musk then made the baseless claim that Unsworth was a paedophile, tweeting, “Sorry pedo guy, you really did ask for it.”

Unsworth later said he was considering legal action against the Tesla CEO for his comments.

Musk’s apology came after Tesla investors posted an open letter online on Tuesday. “The exchange with Vern Unsworth crossed the line,” wrote Loup Ventures, a venture capital firm based in Minneapolis and New York. “I suspect you would agree given you deleted the string from Twitter, but it will take more than that to regain investor confidence.”

“Over the last six months, there have been too many examples of concerning behavior that is shaking investor confidence,” the letter said, pointing out several instances of Musk’s alleged outbursts since March. The investors further said Musk’s behaviour was “fueling an unhelpful perception” of his leadership, calling it “thin-skinned and short-tempered”.

Musk’s behaviour “could have a dramatic negative impact on the company”, Gene Munster, head of research at Loup Ventures, told The Guardian on Tuesday. “It has to start with an apology.”