In reading George Bernard Shaw's 1913 Pygmalion, I found it a bit disjointed. Many of the scenes in the play come out of nowhere, skipping large amounts of time and introducing us to character evolution we had no way of seeing happen. It leads to an unsettling feeling for the reader and for a much less enjoyable experience. Likewise, the 1938 movie version of Pygmalion, directed by Anthony Asquith and Leslie Howard, leaves much to be desired, especially in not preparing the audience for the revised ending. The musical My Fair Lady, written by Alan J. Lerner and Frederick Loewe in 1956 and filmed by George Cukor in 1964, uses songs to fill in these gaps and lift an interesting play into a great musical in which the altered ending makes sense.
The character of Mr. Doolittle gets the most additions. In the play and older movie, he (Wilfred Lawson) comes off as a pointless character who only exists as a way to make fun of the middle class. The musical makes him a more full character, as portrayed by Stanley Holloway. The "With a Little Bit of Luck" sequence shows him amongst his own kind. He is, as I would have imagined, a man who has a group of people who follow him omit--, and others who hate him. It also show the joy that he feels in his vagrant life style when he comes to find out about Eliza's (Audrey Hepburn) twist of fate.
In the 1938 movie version of Pygmalion, the happy ending at the end falls on its face. Pygmalion's forward movement just cannot support an ending where Eliza (Wendy Hiller) and Professor Higgins (Leslie Howard) , as the characters in the original play do not. In the musical; however, the happy ending feels totally natural. This is achieved by the addition of a few essential scenes and songs. The first is the "Rain in Spain" song sequence. Here the audiences get to see Professor Higgins (Rex Harrison) as more than just a cruel taskmaster; instead he has become genuine teacher, whose empathy has caused Eliza's breakthrough. We can better see her forming an emotional attachment to Higgins after this scene and her subsequent ecstatic interpretation of the events in "I Could have Danced All Night."
We then see further evidence that Higgins cares about her and needs her in his "I've Become Accustomed to her Face" number. It is a small song, but it shows an emotional attachment to another human being that is absolutely necessary.
There are other similar scenes in My Fair Lady. The writers of My Fair Lady deserve a great deal of credit for lifting a mediocre play to a great musical movie. It took a good understanding of the characters and what was needed to get to the desired end to accomplish it.