bug fix ... forgot to update a redundancy

dev
Steve L. Nyemba 5 years ago
parent ed86ff0add
commit 1cf9c6e47a

@ -176,6 +176,7 @@ class Binary :
col_count = N
matrix = [ np.zeros(col_count,dtype=np.float32) for i in np.arange(row_count)]
#
# let's create a binary matrix of the feature that was passed in
@ -203,10 +204,12 @@ class Binary :
# Let's treat the case of missing values i.e nulls
#
row_count,col_count = column.size,values.size
if row_count * col_count > size and row_count < size:
N = np.divide(size,row_count).astype(int)
i = np.random.choice(col_count,N)
if col_count > size :
# N = np.divide(size,row_count).astype(int)
# N =
i = np.random.choice(col_count,size)
values = values[-i]
col_count = N
return values
def _Export(self,df) :

Loading…
Cancel
Save