NEMA 3R is raintight
It would be OK in the screened porch, so long as nothing would be stored in front of the panel. In the closet is usually not OK, unless the closet is dedicated electrical, or huge. There must be a 36" deep x 30" wide area in front of the panel, kept clear at all times for access. 110.26
Best option, IMHO is to buy the raintight panel.
Earl