The temperatures outside would have to fall below freezing and stay that way for the whole day before the school would actually close for the day.
During cold weather the schools do have heating but sometimes they'll close if it gets way too cold so kids and other students won't have to walk to school or stand outside in the cold weather waiting for the school bus when it's really cold outside.
Also during really, really cold temperatures it's possible that some schools heating systems may not keep up with the cold temperatures outside and cause it to be too cold inside the school for the students.
I know that when I was in Kindergarten years ago our school decided to let us out because the temperature was below freezing outside and the heater inside could barely keep up and we were wearing our coats inside the school.
It was so great to get back home where our home was really warm.