Added CSV output option