Features added, added CSV output feature, bug fixed