Parents are supposed to be the ones responsible for ensuring the development of their children, for educating them; so it becomes very difficult if the parents themselves are responsible for preventing the growth of the child, or for creating a set of circumstances in which the child cannot develop. In such cases, society has to step in, and ensure that the child is separated from the parents and placed in better circumstances.
In this case as well, where this girl was allowed to go to school, but when home, she would have to stay in a closet; and she was the only child on whom this restriction was placed while her brothers were free. The amount of psychological damage this does to a child can be immense (link to article):
Police officers say a young girl was kept locked away in a closet in a West Brownsville duplex by her parents for about a year. She attended school every day and held steady grades, but once she was home she was not allowed to watch television or play with her brothers, investigators said. The 12-year-old girl had to stay inside the closet.
No one would have known of the abuse, police officers said, if one of her brothers had not reported it to officials at his school, which initiated an investigation by Child Protective Services. “Everyone in the house knew what was going on, but you have children, who based on fear, hold this secret,” Sgt. Jimmy Manrrique, Brownsville Police Department spokesman, said.