|
|
|
@ -58,11 +58,6 @@ def reset(): |
|
|
|
|
global filterActionFinal |
|
|
|
|
filterActionFinal = '' |
|
|
|
|
|
|
|
|
|
global storePositions |
|
|
|
|
global storeReplacements |
|
|
|
|
storePositions = [] |
|
|
|
|
storeReplacements = [] |
|
|
|
|
|
|
|
|
|
global keySpecInternal |
|
|
|
|
keySpecInternal = 1 |
|
|
|
|
|
|
|
|
@ -159,11 +154,6 @@ def retrieveFileName(): |
|
|
|
|
global DataResultsRawTest |
|
|
|
|
global DataRawLengthTest |
|
|
|
|
|
|
|
|
|
global storePositions |
|
|
|
|
global storeReplacements |
|
|
|
|
storePositions = [] |
|
|
|
|
storeReplacements = [] |
|
|
|
|
|
|
|
|
|
global fileName |
|
|
|
|
fileName = [] |
|
|
|
|
fileName = request.get_data().decode('utf8').replace("'", '"') |
|
|
|
@ -481,7 +471,7 @@ def dataSetSelection(): |
|
|
|
|
|
|
|
|
|
global keepOriginalFeatures |
|
|
|
|
keepOriginalFeatures = XData.copy() |
|
|
|
|
keepOriginalFeatures.columns = [str(col) + ' (F'+str(idx+1)+')' for idx, col in enumerate(keepOriginalFeatures.columns)] |
|
|
|
|
keepOriginalFeatures.columns = [str(col) + ' F'+str(idx+1)+'' for idx, col in enumerate(keepOriginalFeatures.columns)] |
|
|
|
|
columnsNewGen = keepOriginalFeatures.columns.values.tolist() |
|
|
|
|
|
|
|
|
|
XData.columns = ['F'+str(idx+1) for idx, col in enumerate(XData.columns)] |
|
|
|
@ -536,6 +526,7 @@ def executeModel(exeCall, flagEx, nodeTransfName): |
|
|
|
|
global listofTransformations |
|
|
|
|
global XDataStoredOriginal |
|
|
|
|
global finalResultsData |
|
|
|
|
global tracker |
|
|
|
|
|
|
|
|
|
global XDataNoRemoval |
|
|
|
|
global XDataNoRemovalOrig |
|
|
|
@ -548,6 +539,11 @@ def executeModel(exeCall, flagEx, nodeTransfName): |
|
|
|
|
if (flagEx == 3): |
|
|
|
|
XDataStored = XData.copy() |
|
|
|
|
XDataNoRemovalOrig = XDataNoRemoval.copy() |
|
|
|
|
elif (flagEx == 2): |
|
|
|
|
XData = XDataStored.copy() |
|
|
|
|
XDataStoredOriginal = XDataStored.copy() |
|
|
|
|
XDataNoRemoval = XDataNoRemovalOrig.copy() |
|
|
|
|
columnsNewGen = keepOriginalFeatures.columns.values.tolist() |
|
|
|
|
else: |
|
|
|
|
XData = XDataStored.copy() |
|
|
|
|
XDataNoRemoval = XDataNoRemovalOrig.copy() |
|
|
|
@ -555,12 +551,19 @@ def executeModel(exeCall, flagEx, nodeTransfName): |
|
|
|
|
else: |
|
|
|
|
if (flagEx == 4): |
|
|
|
|
XDataStored = XData.copy() |
|
|
|
|
XDataNoRemovalOrig = XDataNoRemoval.copy() |
|
|
|
|
print('edw!') |
|
|
|
|
#XDataStoredOriginal = XDataStored.copy() |
|
|
|
|
elif (flagEx == 2): |
|
|
|
|
pass |
|
|
|
|
XData = XDataStored.copy() |
|
|
|
|
XDataStoredOriginal = XDataStored.copy() |
|
|
|
|
XDataNoRemoval = XDataNoRemovalOrig.copy() |
|
|
|
|
columnsNewGen = keepOriginalFeatures.columns.values.tolist() |
|
|
|
|
else: |
|
|
|
|
XData = XDataStored.copy() |
|
|
|
|
#XDataNoRemoval = XDataNoRemovalOrig.copy() |
|
|
|
|
XDataStoredOriginal = XDataStored.copy() |
|
|
|
|
columnsNewGen = keepOriginalFeatures.columns.values.tolist() |
|
|
|
|
|
|
|
|
|
# Bayesian Optimization CHANGE INIT_POINTS! |
|
|
|
|
if (keyFirstTime): |
|
|
|
|
create_global_function() |
|
|
|
@ -569,6 +572,7 @@ def executeModel(exeCall, flagEx, nodeTransfName): |
|
|
|
|
bayesopt.maximize(init_points=10, n_iter=5, acq='ucb') # 35 and 15 |
|
|
|
|
bestParams = bayesopt.max['params'] |
|
|
|
|
estimator = XGBClassifier(n_estimators=int(bestParams.get('n_estimators')), eta=bestParams.get('eta'), max_depth=int(bestParams.get('max_depth')), probability=True, random_state=RANDOM_SEED, silent=True, verbosity = 0, use_label_encoder=False) |
|
|
|
|
columnsNewGen = keepOriginalFeatures.columns.values.tolist() |
|
|
|
|
|
|
|
|
|
if (len(exeCall) != 0): |
|
|
|
|
if (flagEx == 1): |
|
|
|
@ -588,18 +592,20 @@ def executeModel(exeCall, flagEx, nodeTransfName): |
|
|
|
|
XDataNoRemoval[columnsKeepNew] = XDataTemp.values |
|
|
|
|
elif (flagEx == 4): |
|
|
|
|
splittedCol = nodeTransfName.split('_') |
|
|
|
|
XData.rename(columns={ XData.columns[exeCall[0]]: nodeTransfName }, inplace = True) |
|
|
|
|
for col in XDataNoRemoval.columns: |
|
|
|
|
if ((splittedCol[0] in col)): |
|
|
|
|
storeRenamedColumn = col |
|
|
|
|
XData.rename(columns={ storeRenamedColumn: nodeTransfName }, inplace = True) |
|
|
|
|
XDataNoRemoval.rename(columns={ storeRenamedColumn: nodeTransfName }, inplace = True) |
|
|
|
|
currentColumn = columnsNewGen[exeCall[0]] |
|
|
|
|
subString = currentColumn[currentColumn.find("(")+1:currentColumn.find(")")] |
|
|
|
|
replacement = currentColumn.replace(subString, nodeTransfName) |
|
|
|
|
storePositions.append(exeCall[0]) |
|
|
|
|
storeReplacements.append(replacement) |
|
|
|
|
pos = 0 |
|
|
|
|
for repl in storeReplacements: |
|
|
|
|
columnsNewGen[storePositions[pos]] = repl |
|
|
|
|
pos += 1 |
|
|
|
|
for ind, column in enumerate(columnsNewGen): |
|
|
|
|
if ((splittedCol[0] in column)): |
|
|
|
|
columnsNewGen[ind] = columnsNewGen[ind].replace(storeRenamedColumn, nodeTransfName) |
|
|
|
|
if (len(splittedCol) == 1): |
|
|
|
|
XData[nodeTransfName] = XDataStoredOriginal[nodeTransfName] |
|
|
|
|
XDataNoRemoval[nodeTransfName] = XDataStoredOriginal[nodeTransfName] |
|
|
|
|
else: |
|
|
|
|
if (splittedCol[1] == 'r'): |
|
|
|
|
XData[nodeTransfName] = XData[nodeTransfName].round() |
|
|
|
@ -653,10 +659,35 @@ def executeModel(exeCall, flagEx, nodeTransfName): |
|
|
|
|
XData[nodeTransfName] = np.power(XData[nodeTransfName], 3) |
|
|
|
|
else: |
|
|
|
|
XData[nodeTransfName] = np.power(XData[nodeTransfName], 4) |
|
|
|
|
XDataStored = XData.copy() |
|
|
|
|
XDataNoRemoval[nodeTransfName] = XData[nodeTransfName] |
|
|
|
|
XDataStored = XData.copy() |
|
|
|
|
XDataNoRemovalOrig = XDataNoRemoval.copy() |
|
|
|
|
|
|
|
|
|
columnsNamesLoc = XData.columns.values.tolist() |
|
|
|
|
|
|
|
|
|
tracker = [] |
|
|
|
|
for value in columnsNewGen: |
|
|
|
|
value = value.split(' ') |
|
|
|
|
if (len(value) > 1): |
|
|
|
|
tracker.append(value[1]) |
|
|
|
|
else: |
|
|
|
|
tracker.append(value[0]) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
storeIndices = [] |
|
|
|
|
valuesStore = [] |
|
|
|
|
for ind, col in enumerate(tracker): |
|
|
|
|
for value in XDataStoredOriginal.columns.values.tolist(): |
|
|
|
|
if col in value: |
|
|
|
|
storeIndices.append(ind) |
|
|
|
|
valuesStore.append(valuesStore) |
|
|
|
|
tracker[ind] = tracker[ind].replace(col, value) |
|
|
|
|
else: |
|
|
|
|
break |
|
|
|
|
# FIX THAT! |
|
|
|
|
#for el in storeIndices: |
|
|
|
|
# columnsNewGen[el] = columnsNewGen[el].replace(columnsNewGen[el],valuesStore[el]) |
|
|
|
|
#print(columnsNewGen) |
|
|
|
|
for col in columnsNamesLoc: |
|
|
|
|
splittedCol = col.split('_') |
|
|
|
|
if (len(splittedCol) == 1): |
|
|
|
@ -669,10 +700,14 @@ def executeModel(exeCall, flagEx, nodeTransfName): |
|
|
|
|
else: |
|
|
|
|
columnsNames.append(splittedCol[0]+'_'+tran) |
|
|
|
|
featureImportanceData = estimatorFeatureSelection(XDataNoRemoval, estimator) |
|
|
|
|
print(XData) |
|
|
|
|
print(XDataStored) |
|
|
|
|
print(XDataStoredOriginal.columns) |
|
|
|
|
print(XDataNoRemoval) |
|
|
|
|
estimator.fit(XData, yData) |
|
|
|
|
yPredict = estimator.predict(XData) |
|
|
|
|
yPredictProb = cross_val_predict(estimator, XData, yData, cv=crossValidation, method='predict_proba') |
|
|
|
|
print(XData) |
|
|
|
|
|
|
|
|
|
num_cores = multiprocessing.cpu_count() |
|
|
|
|
inputsSc = ['accuracy','precision_macro','recall_macro'] |
|
|
|
|
|
|
|
|
@ -738,7 +773,7 @@ def featFun (clfLocalPar,DataLocalPar,yDataLocalPar): |
|
|
|
|
# # calculating for all algorithms and models the performance and other results |
|
|
|
|
# @memory.cache |
|
|
|
|
def estimatorFeatureSelection(Data, clf): |
|
|
|
|
print(Data) |
|
|
|
|
|
|
|
|
|
resultsFS = [] |
|
|
|
|
permList = [] |
|
|
|
|
PerFeatureAccuracy = [] |
|
|
|
@ -1715,7 +1750,7 @@ def Seperation(): |
|
|
|
|
packCorr.append(json.dumps(MI4List)) |
|
|
|
|
packCorr.append(json.dumps(MI5List)) |
|
|
|
|
|
|
|
|
|
packCorr.append(list(XDataStored.columns.values.tolist())) |
|
|
|
|
packCorr.append(list(tracker)) |
|
|
|
|
packCorr.append(list(XData.columns.values.tolist())) |
|
|
|
|
packCorr.append(json.dumps(columnsNames)) |
|
|
|
|
|
|
|
|
@ -1776,6 +1811,7 @@ def CompareFunPy(): |
|
|
|
|
global columnsKeep |
|
|
|
|
global XDataGen |
|
|
|
|
global IDsToCompare |
|
|
|
|
global columnsNewGen |
|
|
|
|
|
|
|
|
|
retrieveComparison = request.get_data().decode('utf8').replace("'", '"') |
|
|
|
|
retrieveComparison = json.loads(retrieveComparison) |
|
|
|
@ -1783,7 +1819,8 @@ def CompareFunPy(): |
|
|
|
|
IDsToCompare = retrieveComparison['getIDs'] |
|
|
|
|
XDataGen = XDataStored.copy() |
|
|
|
|
columns = XData.columns.values.tolist() |
|
|
|
|
columnsOriganl = keepOriginalFeatures.columns.values.tolist() |
|
|
|
|
#columnsOriganl = XDataNoRemoval.columns.values.tolist() |
|
|
|
|
|
|
|
|
|
columnsKeep = [] |
|
|
|
|
columnsKeepNonOrig = [] |
|
|
|
|
columnsKeepID = [] |
|
|
|
@ -1791,76 +1828,76 @@ def CompareFunPy(): |
|
|
|
|
if indx in IDsToCompare: |
|
|
|
|
columnsKeepNonOrig.append(col) |
|
|
|
|
columnExtracted = re.findall('\d+', col) |
|
|
|
|
columnsKeep.append(columnsOriganl[int(columnExtracted[0]) - 1]) |
|
|
|
|
columnsKeepID.append(str(int(columnExtracted[0]))) |
|
|
|
|
columnsKeep.append(columnsNewGen[int(columnExtracted[0]) - 1]) |
|
|
|
|
columnsKeepID.append(str(col)) |
|
|
|
|
if (compareMode == 1): |
|
|
|
|
XDataGen = XData[columnsKeepNonOrig] |
|
|
|
|
feat1 = XDataGen.iloc[:,0] |
|
|
|
|
feat2 = XDataGen.iloc[:,1] |
|
|
|
|
XDataGen['F'+columnsKeepID[0]+'+F'+columnsKeepID[1]] = feat1 + feat2 |
|
|
|
|
XDataGen['|F'+columnsKeepID[0]+'-F'+columnsKeepID[1]+'|'] = abs(feat1 - feat2) |
|
|
|
|
XDataGen['F'+columnsKeepID[0]+'xF'+columnsKeepID[1]] = feat1 * feat2 |
|
|
|
|
XDataGen['F'+columnsKeepID[0]+'/F'+columnsKeepID[1]] = feat1 / feat2 |
|
|
|
|
XDataGen['F'+columnsKeepID[1]+'/F'+columnsKeepID[0]] = feat2 / feat1 |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[0]+'+F'+columnsKeepID[1]) |
|
|
|
|
columnsKeep.append('|F'+columnsKeepID[0]+'-F'+columnsKeepID[1]+'|') |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[0]+'xF'+columnsKeepID[1]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[0]+'/F'+columnsKeepID[1]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[1]+'/F'+columnsKeepID[0]) |
|
|
|
|
XDataGen[columnsKeepID[0]+'+'+columnsKeepID[1]] = feat1 + feat2 |
|
|
|
|
XDataGen['|'+columnsKeepID[0]+'-'+columnsKeepID[1]+'|'] = abs(feat1 - feat2) |
|
|
|
|
XDataGen[columnsKeepID[0]+'x'+columnsKeepID[1]] = feat1 * feat2 |
|
|
|
|
XDataGen[columnsKeepID[0]+'/'+columnsKeepID[1]] = feat1 / feat2 |
|
|
|
|
XDataGen[columnsKeepID[1]+'/'+columnsKeepID[0]] = feat2 / feat1 |
|
|
|
|
columnsKeep.append(columnsKeepID[0]+'+'+columnsKeepID[1]) |
|
|
|
|
columnsKeep.append('|'+columnsKeepID[0]+'-'+columnsKeepID[1]+'|') |
|
|
|
|
columnsKeep.append(columnsKeepID[0]+'x'+columnsKeepID[1]) |
|
|
|
|
columnsKeep.append(columnsKeepID[0]+'/'+columnsKeepID[1]) |
|
|
|
|
columnsKeep.append(columnsKeepID[1]+'/'+columnsKeepID[0]) |
|
|
|
|
elif (compareMode == 2): |
|
|
|
|
XDataGen = XData[columnsKeepNonOrig] |
|
|
|
|
feat1 = XDataGen.iloc[:,0] |
|
|
|
|
feat2 = XDataGen.iloc[:,1] |
|
|
|
|
feat3 = XDataGen.iloc[:,2] |
|
|
|
|
XDataGen['F'+columnsKeepID[0]+'+F'+columnsKeepID[1]] = feat1 + feat2 |
|
|
|
|
XDataGen['F'+columnsKeepID[1]+'+F'+columnsKeepID[2]] = feat2 + feat3 |
|
|
|
|
XDataGen['F'+columnsKeepID[0]+'+F'+columnsKeepID[2]] = feat1 + feat3 |
|
|
|
|
XDataGen['F'+columnsKeepID[0]+'+F'+columnsKeepID[1]+'+F'+columnsKeepID[2]] = feat1 + feat2 + feat3 |
|
|
|
|
XDataGen['|F'+columnsKeepID[0]+'-F'+columnsKeepID[1]+'|'] = abs(feat1 - feat2) |
|
|
|
|
XDataGen['|F'+columnsKeepID[1]+'-F'+columnsKeepID[2]+'|'] = abs(feat2 - feat3) |
|
|
|
|
XDataGen['|F'+columnsKeepID[0]+'-F'+columnsKeepID[2]+'|'] = abs(feat1 - feat3) |
|
|
|
|
XDataGen['|F'+columnsKeepID[0]+'-F'+columnsKeepID[1]+'-F'+columnsKeepID[2]+'|'] = abs(feat1 - feat2 - feat3) |
|
|
|
|
XDataGen['F'+columnsKeepID[0]+'xF'+columnsKeepID[1]] = feat1 * feat2 |
|
|
|
|
XDataGen['F'+columnsKeepID[1]+'xF'+columnsKeepID[2]] = feat2 * feat3 |
|
|
|
|
XDataGen['F'+columnsKeepID[0]+'xF'+columnsKeepID[2]] = feat1 * feat3 |
|
|
|
|
XDataGen['F'+columnsKeepID[0]+'xF'+columnsKeepID[1]+'xF'+columnsKeepID[2]] = feat1 * feat2 * feat3 |
|
|
|
|
XDataGen['F'+columnsKeepID[0]+'/F'+columnsKeepID[1]] = feat1 / feat2 |
|
|
|
|
XDataGen['F'+columnsKeepID[1]+'/F'+columnsKeepID[0]] = feat2 / feat1 |
|
|
|
|
XDataGen['F'+columnsKeepID[1]+'/F'+columnsKeepID[2]] = feat2 / feat3 |
|
|
|
|
XDataGen['F'+columnsKeepID[2]+'/F'+columnsKeepID[1]] = feat3 / feat2 |
|
|
|
|
XDataGen['F'+columnsKeepID[0]+'/F'+columnsKeepID[2]] = feat1 / feat3 |
|
|
|
|
XDataGen['F'+columnsKeepID[2]+'/F'+columnsKeepID[0]] = feat3 / feat1 |
|
|
|
|
XDataGen['F'+columnsKeepID[0]+'/F'+columnsKeepID[1]+'/F'+columnsKeepID[2]] = feat1 / feat2 / feat3 |
|
|
|
|
XDataGen['F'+columnsKeepID[0]+'/F'+columnsKeepID[2]+'/F'+columnsKeepID[1]] = feat1 / feat3 / feat2 |
|
|
|
|
XDataGen['F'+columnsKeepID[1]+'/F'+columnsKeepID[2]+'/F'+columnsKeepID[0]] = feat2 / feat3 / feat1 |
|
|
|
|
XDataGen['F'+columnsKeepID[1]+'/F'+columnsKeepID[0]+'/F'+columnsKeepID[2]] = feat2 / feat1 / feat3 |
|
|
|
|
XDataGen['F'+columnsKeepID[2]+'/F'+columnsKeepID[0]+'/F'+columnsKeepID[1]] = feat3 / feat1 / feat2 |
|
|
|
|
XDataGen['F'+columnsKeepID[2]+'/F'+columnsKeepID[1]+'/F'+columnsKeepID[0]] = feat3 / feat2 / feat1 |
|
|
|
|
|
|
|
|
|
columnsKeep.append('F'+columnsKeepID[0]+'+F'+columnsKeepID[1]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[1]+'+F'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[0]+'+F'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[0]+'+F'+columnsKeepID[1]+'+F'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append('|F'+columnsKeepID[0]+'-F'+columnsKeepID[1]+'|') |
|
|
|
|
columnsKeep.append('|F'+columnsKeepID[1]+'-F'+columnsKeepID[2]+'|') |
|
|
|
|
columnsKeep.append('|F'+columnsKeepID[0]+'-F'+columnsKeepID[2]+'|') |
|
|
|
|
columnsKeep.append('|F'+columnsKeepID[0]+'-F'+columnsKeepID[1]+'-F'+columnsKeepID[2]+'|') |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[0]+'xF'+columnsKeepID[1]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[1]+'xF'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[0]+'xF'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[0]+'xF'+columnsKeepID[1]+'xF'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[0]+'/F'+columnsKeepID[1]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[1]+'/F'+columnsKeepID[0]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[1]+'/F'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[2]+'/F'+columnsKeepID[1]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[0]+'/F'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[2]+'/F'+columnsKeepID[0]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[0]+'/F'+columnsKeepID[1]+'/F'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[0]+'/F'+columnsKeepID[2]+'/F'+columnsKeepID[1]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[1]+'/F'+columnsKeepID[2]+'/F'+columnsKeepID[0]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[1]+'/F'+columnsKeepID[0]+'/F'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[2]+'/F'+columnsKeepID[0]+'/F'+columnsKeepID[1]) |
|
|
|
|
columnsKeep.append('F'+columnsKeepID[2]+'/F'+columnsKeepID[1]+'/F'+columnsKeepID[0]) |
|
|
|
|
XDataGen[columnsKeepID[0]+'+'+columnsKeepID[1]] = feat1 + feat2 |
|
|
|
|
XDataGen[columnsKeepID[1]+'+'+columnsKeepID[2]] = feat2 + feat3 |
|
|
|
|
XDataGen[columnsKeepID[0]+'+'+columnsKeepID[2]] = feat1 + feat3 |
|
|
|
|
XDataGen[columnsKeepID[0]+'+'+columnsKeepID[1]+'+'+columnsKeepID[2]] = feat1 + feat2 + feat3 |
|
|
|
|
XDataGen['|'+columnsKeepID[0]+'-'+columnsKeepID[1]+'|'] = abs(feat1 - feat2) |
|
|
|
|
XDataGen['|'+columnsKeepID[1]+'-'+columnsKeepID[2]+'|'] = abs(feat2 - feat3) |
|
|
|
|
XDataGen['|'+columnsKeepID[0]+'-'+columnsKeepID[2]+'|'] = abs(feat1 - feat3) |
|
|
|
|
XDataGen['|'+columnsKeepID[0]+'-'+columnsKeepID[1]+'-'+columnsKeepID[2]+'|'] = abs(feat1 - feat2 - feat3) |
|
|
|
|
XDataGen[columnsKeepID[0]+'x'+columnsKeepID[1]] = feat1 * feat2 |
|
|
|
|
XDataGen[columnsKeepID[1]+'x'+columnsKeepID[2]] = feat2 * feat3 |
|
|
|
|
XDataGen[columnsKeepID[0]+'x'+columnsKeepID[2]] = feat1 * feat3 |
|
|
|
|
XDataGen[columnsKeepID[0]+'x'+columnsKeepID[1]+'x'+columnsKeepID[2]] = feat1 * feat2 * feat3 |
|
|
|
|
XDataGen[columnsKeepID[0]+'/'+columnsKeepID[1]] = feat1 / feat2 |
|
|
|
|
XDataGen[columnsKeepID[1]+'/'+columnsKeepID[0]] = feat2 / feat1 |
|
|
|
|
XDataGen[columnsKeepID[1]+'/'+columnsKeepID[2]] = feat2 / feat3 |
|
|
|
|
XDataGen[columnsKeepID[2]+'/'+columnsKeepID[1]] = feat3 / feat2 |
|
|
|
|
XDataGen[columnsKeepID[0]+'/'+columnsKeepID[2]] = feat1 / feat3 |
|
|
|
|
XDataGen[columnsKeepID[2]+'/'+columnsKeepID[0]] = feat3 / feat1 |
|
|
|
|
XDataGen[columnsKeepID[0]+'/'+columnsKeepID[1]+'/'+columnsKeepID[2]] = feat1 / feat2 / feat3 |
|
|
|
|
XDataGen[columnsKeepID[0]+'/'+columnsKeepID[2]+'/'+columnsKeepID[1]] = feat1 / feat3 / feat2 |
|
|
|
|
XDataGen[columnsKeepID[1]+'/'+columnsKeepID[2]+'/'+columnsKeepID[0]] = feat2 / feat3 / feat1 |
|
|
|
|
XDataGen[columnsKeepID[1]+'/'+columnsKeepID[0]+'/'+columnsKeepID[2]] = feat2 / feat1 / feat3 |
|
|
|
|
XDataGen[columnsKeepID[2]+'/'+columnsKeepID[0]+'/'+columnsKeepID[1]] = feat3 / feat1 / feat2 |
|
|
|
|
XDataGen[columnsKeepID[2]+'/'+columnsKeepID[1]+'/'+columnsKeepID[0]] = feat3 / feat2 / feat1 |
|
|
|
|
|
|
|
|
|
columnsKeep.append(columnsKeepID[0]+'+'+columnsKeepID[1]) |
|
|
|
|
columnsKeep.append(columnsKeepID[1]+'+'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append(columnsKeepID[0]+'+'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append(columnsKeepID[0]+'+'+columnsKeepID[1]+'+'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append('|'+columnsKeepID[0]+'-'+columnsKeepID[1]+'|') |
|
|
|
|
columnsKeep.append('|'+columnsKeepID[1]+'-'+columnsKeepID[2]+'|') |
|
|
|
|
columnsKeep.append('|'+columnsKeepID[0]+'-'+columnsKeepID[2]+'|') |
|
|
|
|
columnsKeep.append('|'+columnsKeepID[0]+'-'+columnsKeepID[1]+'-'+columnsKeepID[2]+'|') |
|
|
|
|
columnsKeep.append(columnsKeepID[0]+'x'+columnsKeepID[1]) |
|
|
|
|
columnsKeep.append(columnsKeepID[1]+'x'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append(columnsKeepID[0]+'x'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append(columnsKeepID[0]+'x'+columnsKeepID[1]+'x'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append(columnsKeepID[0]+'/'+columnsKeepID[1]) |
|
|
|
|
columnsKeep.append(columnsKeepID[1]+'/'+columnsKeepID[0]) |
|
|
|
|
columnsKeep.append(columnsKeepID[1]+'/'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append(columnsKeepID[2]+'/'+columnsKeepID[1]) |
|
|
|
|
columnsKeep.append(columnsKeepID[0]+'/'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append(columnsKeepID[2]+'/'+columnsKeepID[0]) |
|
|
|
|
columnsKeep.append(columnsKeepID[0]+'/'+columnsKeepID[1]+'/'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append(columnsKeepID[0]+'/'+columnsKeepID[2]+'/'+columnsKeepID[1]) |
|
|
|
|
columnsKeep.append(columnsKeepID[1]+'/'+columnsKeepID[2]+'/'+columnsKeepID[0]) |
|
|
|
|
columnsKeep.append(columnsKeepID[1]+'/'+columnsKeepID[0]+'/'+columnsKeepID[2]) |
|
|
|
|
columnsKeep.append(columnsKeepID[2]+'/'+columnsKeepID[0]+'/'+columnsKeepID[1]) |
|
|
|
|
columnsKeep.append(columnsKeepID[2]+'/'+columnsKeepID[1]+'/'+columnsKeepID[0]) |
|
|
|
|
else: |
|
|
|
|
pass |
|
|
|
|
featureCompareData = estimatorFeatureSelection(XDataGen, estimator) |
|
|
|
|