# TODO: Load the csv files into dataframes here.
import csv
import pandas

class data_preparer():
    def __init__(self):
        pass
    def load(self, filename):
        # X = pandas.DataFrame()
        # with open(filename) as csvfile:
        #     filereader = csv.reader(csvfile,delimiter=',')
        X = pandas.read_csv(filename)
        return X
    def sv_detection(self):
        data_1 = pandas.read_csv('Sat Mar  4 00:44:23 2017')
        data_2 = pandas.read_csv('Sat Mar  4 00:45:02 2017')
        data_3 = pandas.read_csv('Sat Mar  4 00:45:47 2017')
        data_4 = pandas.read_csv('Sat Mar  4 00:47:01 2017')
        data_5 = pandas.read_csv('Sat Mar  4 00:47:36 2017')
        # Select a few portions of the above datafiles that most likely contain little or no specific subvocalization, SV.
        no_sv = data_1[:3000].append([data_2[:2000],data_3[:2000],data_4[:2000],data_5[:2000]],ignore_index=True)
        # Now select a few portions that most likely do contain some specific SV.
        with_sv = data_1[5000:9000].append([data_2[6000:10000],data_3[3000:9000]],ignore_index=True)

        return no_sv, with_sv

@@ -852,43 +852,103 @@
 ata_
-2%5B:2000%5D,data_3%5B:2000%5D,data_4%5B:2000
+1%5B24000:%5D,data_2%5B:2000%5D,data_2%5B19500:%5D,data_3%5B:2000%5D,data_3%5B19000:%5D,data_4%5B:2000%5D,data_4%5B19000:
 %5D,da
@@ -1114,35 +1114,116 @@
 ata_
-2%5B6000:10000%5D,data_3%5B3000:9
+1%5B15000:20000%5D,data_2%5B6000:10000%5D, data_2%5B12000:18000%5D,data_2%5B20000:25000%5D,data_3%5B3000:9000%5D,data_3%5B12000:14
 000%5D

Include more samples