ENH: through use of "with" statement, closing file manually is no longer necessary