added a check to outpath in classes.Series.write____ functions