The Hammers conceded nine goals in their opening three games in the top flight, while the club also sat bottom of the standings after four successive defeats.
However, the East London outfit have shipped just one goal in their last three fixtures in all competitions, and Pellegrini has admitted that he is delighted with the improvement in recent weeks.
At a press conference, the 65-year-old told reporters: "I'm very happy, not only for Fabian [Balbuena] and [Issa] Diop, but also Angelo Ogbonna's performance on Wednesday.
"I think we are defensively improving. I knew Diop well. He was the captain of Toulouse. I told him he needed to know a bit more about the Premier League, but I was absolutely sure he would be a success here."
West Ham play host to Manchester United at the London Stadium on Saturday afternoon.