import csv

class Normalizer():
    def conv(self, i, j, s):
        try:
            s = float(s)
        except ValueError:
            if j in self.colFloat:
                if (self.header and i > 0) or not self.header:
                    self.colFloat.remove(j)
        return s

    def __init__(self, dataFile, header):
        self.data = []
        defCol = True
        self.header = header
        with open(dataFile, 'rU') as desc:
            reader = csv.reader(desc)
            i = 0
            for row in reader:
                if defCol:
                    defCol = False
                    self.colFloat = [x for x in range(len(row))]
                rowRes = []
                j = 0
                for cell in row:
                    cell = self.conv(i, j, cell)
                    rowRes.append(cell)
                    j += 1
                self.data.append(rowRes)
                i += 1
        if header:
            self.data.pop(0)

    def getColFloat(self):
        return self.colFloat

    def getData(self):
        return self.data

@@ -4,16 +4,36 @@
 ort csv%0D
+%0Aimport numpy as np%0D
 %0A%0D%0Aclass
@@ -60,147 +60,85 @@
 def 
-conv(self, i, j, s):%0D%0A        try:%0D%0A            s = float(s)%0D%0A        except ValueError:%0D%0A            if j in self.colFloat:%0D%0A     
+__init__(self, dataFile, header):%0D%0A        self.dataFile = dataFile%0D%0A
         
    i
@@ -137,15 +137,8 @@
     
-   if (
 self
@@ -149,144 +149,39 @@
 der 
-and i %3E 0) or not self.header:%0D%0A                    self.colFloat.remove(j)%0D%0A        return s%0D%0A%0D%0A    def __init__(self, dataFile, header
+= header%0D%0A%0D%0A    def getCol(self
 ):%0D%0A
@@ -188,25 +188,19 @@
         
-self.data
+res
  = %5B%5D%0D%0A 
@@ -210,51 +210,13 @@
     
-defCol = True%0D%0A        self.header = header
+i = 0
 %0D%0A  
@@ -231,16 +231,21 @@
 th open(
+self.
 dataFile
@@ -305,27 +305,8 @@
 c)%0D%0A
-            i = 0%0D%0A
     
@@ -353,17 +353,23 @@
     
-if defCol
+for cell in row
 :%0D%0A 
@@ -391,22 +391,23 @@
     
-defCol = False
+if self.header:
 %0D%0A  
@@ -428,52 +428,28 @@
     
-self.colFloat = %5Bx for x in range(len(row))%5D
+    res.append(cell)
 %0D%0A  
@@ -466,19 +466,17 @@
     
-rowRes = %5B%5D
+    else:
 %0D%0A  
@@ -493,97 +493,57 @@
     
-j = 0%0D%0A                for cell in row:%0D%0A                    cell = self.conv(i, j, cell)
+        res.append(i)%0D%0A                    i += 1
 %0D%0A  
@@ -560,31 +560,18 @@
     
- 
-   rowRes.append(cell)
+return res
 %0D%0A  
@@ -584,38 +584,48 @@
     
- 
-       j += 1%0D%0A      
+%0D%0A%0D%0A    def run(self, fields):%0D%0A
         
   se
@@ -624,34 +624,23 @@
     
- 
+if
  self.
-data.append(rowRes)
+header:
 %0D%0A  
@@ -641,39 +641,37 @@
 r:%0D%0A            
-    i +
+head 
 = 1%0D%0A        if 
@@ -671,17 +671,12 @@
     
-if header
+else
 :%0D%0A 
@@ -690,84 +690,120 @@
     
-self.data.pop(0)%0D%0A%0D%0A    def getColFloat(self):%0D%0A        return self.colFloat
+head = 0%0D%0A        self.data = np.loadtxt(open(self.dataFile,%22rb%22), usecols=fields, delimiter=%22,%22, skiprows=head)
 %0D%0A%0D%0A
@@ -841,16 +841,25 @@
  return 
+np.array(
 self.dat
@@ -859,10 +859,11 @@
 elf.data
+)
 %0D%0A

Change norma to numpy