The multiple settings of the story add to the theme of hope and despair. The family moves and each time adds hope to the children that the move will change their future for the better. Jeanette feels the most hope in her father for change and this is fueled by the promise of the glass castle.
The last home, before the move to New York, gives the most hope to the family. The children believe so much in the hope for the future that they actually dig the foundation for the glass castle promised to them. When the family fills that hole with garbage, Jeanette gave up on the feelings of hope, and despair replaces that hope, with the knowledge that her father's promise is also garbage.
The move to New York is the final setting that shows the children's only hope to have a better future lies within themselves. Their hope in their parents is completely gone and replaced with despair and disappointment.
There are several settings for the story, the house in Arizona, the desert cabin, then the cabin in West Virginia. They all start to share certain characteristics, even the nicely furnished home in Arizona after a while. The parents are somewhat neglectful, so things are always in disarray and generally disorganized. The kids make their own way through their crazy lives as the parents are gone often and apparently disinterested at other times.
This backdrop of disorganization and neglect forms the backbone for the kids learning so much from each other and finding ways to not only survive, but still feel loved and valuable though at times they face serious obstacles to such feelings. In some ways that constant changes serve only to highlight the strength with which the children held onto their image of their family and their own self-worth.