You are on page 1of 14

STIN 5014 (ARTIFICIAL INTELLIGENCE

Assignment II (20 %)
Instructor: Dr. Juhaida Abu Bakar
Submission date: 14th November 2020

Instruction: Answer all questions and submit your answers via UUM Online Learning Portal before
11.59 pm –14th November 2020.

This assignment will require you to implement and interpret some of the data analytics concepts that were
introduced in class using both Python programming language and KNIME toolkits. Keep in mind that the main
objective of this assignment is to highlight the insights that we can derive from applying these techniques—the
coding aspect is secondary. Accordingly, you are welcome to consult any online documentation and/or code
that has been posted to the course website, so long as all references and sources are properly cited.
Part A (Manual & Python Programming):
A group of UUM lecturers have an intention to develop a system that can predict whether a UUM’s graduate that has
completed their undergraduate study will be offered a job, continue their study or received no jobs offer. An example of
the collected data is Table 1 given below.

Table 1
Matric Gender Status EntryQualification CGPA English
level
22619 Male Working Matriculation 3.67 Good
22417 Female Further STPM 3.00 Moderate
Study
22353 Female Unemployed STPM 3.10 Poor
22456 Male Further Diploma 2.45 Poor
Study
33451 Female Working STPM 2.51 Good

Using the following techniques, find the most appropriate decision for these new cases.

Matric Gender Status EntryQualification CGPA English


level
23849 Female ? Diploma 3.5 Moderate
61088 Male ? Matriculation 2.98 Good
31752 Female ? STPM 3.9 Poor

1) K-Nearest Neighbours (K=3).

Matric Gender Status EntryQualification CGPA English


level
22619 1 Working 0 3.67 1
22417 0 Further -1 3.00 0
Study
22353 0 Unemployed -1 3.10 -1
22456 1 Further 1 2.45 -1
Study
33451 0 Working -1 2.51 1
For Matric : 23849
• dist ( 22619,23849 )=√ ¿ ¿+( 1−0 )2 + ( 0−1 )2 + ( 0−1 )2 ¿ = 1.7  1: working
• dist ( 22417,23849 )=√ ¿ ¿+( 1−(−1) )2 + ( 0−0 )2 + ( 0−0 )2 ¿ = 2.1  3: further study
• dist ( 22353,23849 )=√ ¿ ¿+( 1−(−1) )2 + ( 0−(−1) )2 + ( 0−0 )2 ¿ = 2.3
• dist ( 22456,23849 )=√ ¿ ¿+( 1−1 )2 + ( 0−(−1) )2 + ( 0−1 )2 ¿ = 1.8  2: further study
• dist ( 22619,23849 )=√ ¿ ¿+( 1−(−1) )2 + ( 0−1 )2 + ( 0−0 )2 ¿ = 2.4
• Case scores 2 further study and 1 working, therefore decision =“further study”

For Matric : 61088


• dist ( 22619,61088 )=√ ¿ ¿+( 0−0 )2 + ( 1−1 )2+ ( 1−1 )2 ¿ = 0.7  1: working
• dist ( 22417,61088 )=√ ¿ ¿+( 0−(−1) )2 + ( 1−0 )2 + ( 1−0 )2 ¿ = 1.7
• dist ( 22353,61088 )=√ ¿ ¿+( 0−(−1) )2 + ( 1−(−1) )2 + ( 1−0 )2 ¿ = 1.4  2: unemployed
• dist ( 22456,61088 )=√ ¿ ¿+( 0−1 )2 + ( 1−(−1) )2 + ( 1−1 )2 ¿ = 2.3
• dist ( 22619,61088 )=√ ¿ ¿+( 0−(−1) )2 + ( 1−1 )2 + ( 1−0 )2 ¿ = 1.5  3: working
• dist ( 23849 , 61088 )=√ ¿ ¿+( 0−1 )2 + ( 1−0 )2 + ( 1−0 )2 ¿ = 1.8
• Case scores 2 working and 1 unemployed, therefore decision =“working”

For Matric : 31752


• dist ( 22619,31752 )=√ ¿ ¿+(−1−0 )2 + (−1−1 )2 + ( 0−1 )2 ¿ = 2.5
• dist ( 22417,31752 )=√ ¿ ¿+(−1−(−1) )2 + (−1−0 )2 + ( 0−0 )2 ¿ = 1.3  2: further study
• dist ( 22353,31752 )=√ ¿ ¿+(−1−(−1) )2 + (−1−(−1) )2 + ( 0−0 )2 ¿ = 0.8  1: unemployed
• dist ( 22456,31752 )=√ ¿ ¿+(−1−1 )2 + (−1−(−1) )2 + ( 0−1 )2 ¿ = 2.6
• dist ( 22619,31752 )=√ ¿ ¿+(−1−(−1) )2 + (−1−1 )2 + ( 0−0 )2 ¿ = 2.4
• dist ( 23849,31752 )=√ ¿ ¿+(−1−1 )2 + (−1−0 )2 + ( 0−0 )2 ¿ = 2.3  3: further study
• dist ( 61088,31752 )=√ ¿ ¿+(−1−0 )2 + (−1−1 )2 + ( 0−1 )2 ¿ = 2.6
• Case scores 2 further study and 1 unemployed, therefore decision =“further study”

2) Case Based Reasoning (assuming all attributes are equally important and ∑ w=1) and the
highest similarity.

For Matric : 23849

Compute all local similarities:


• local¿ (22619 , 23849)=min ¿ = 0.14
• local_sim_EQ(22619,23849) = matric  diploma = 1
• local_sim_EL(22619,23849) = good  moderate = 1
• local_sim_Gen(22619,23849) = male  female = 1

• local¿ (22417 , 23849)=min ¿ = 0.41


• local_sim_EQ(22417,23849) = STPM  diploma = 1
• local_sim_EL(22417,23849) = mpderate = moderate = 0
• local_sim_Gen(22417,23849) = female = female = 0
• local¿ (22353 , 23849)=min ¿ = 0.33
• local_sim_EQ(22353,23849) = STPM  diploma = 1
• local_sim_EL(22353,23849) = poor  moderate = 1
• local_sim_Gen(22353,23849) = female = female = 0

• local¿ (22456 , 23849)=min ¿ = 0.86


• local_sim_EQ(22456,23849) = diploma = diploma = 0
• local_sim_EL(22456,23849) = poor  moderate = 1
• local_sim_Gen(22456,23849) = male  female = 1

• local¿ (33451 ,23849)=min¿ = 0.81


• local_sim_EQ(33451,23849) = STPM  diploma = 1
• local_sim_EL(33451,23849) = good  moderate = 1
• local_sim_Gen(33451,23849) = female = female = 0

Compute global similarities (equal weightage):


• global¿ (22619,23849)=¿
• global¿ (22417,23849)=¿
• global¿ (22353,23849)=¿
• global¿ (22456,23849)=¿
• global¿ ( 33451,23849)=¿

Decision: Further study as previous similar record is 22417 with 65 % chance of


similarity : further study

For Matric : 61088

Compute all local similarities:


• local¿ (22619 , 61088)=min ¿ = 0.57
• local_sim_EQ(22619,61088) = matric = matric = 0
• local_sim_EL(22619,61088) = good = good = 0
• local_sim_Gen(22619,61088) = male = male = 0

• local¿ (22417 , 61088)=min ¿ = 0.02


• local_sim_EQ(22417,61088) = STPM  matric = 1
• local_sim_EL(22417,61088) = moderate  good = 1
• local_sim_Gen(22417,61088) = female  male = 1

• local¿ (22353 , 61088)=min ¿ = 0.10


• local_sim_EQ(22353,61088) = STPM  matric = 1
• local_sim_EL(22353,61088) = poor  good = 1
• local_sim_Gen(22353,61088) = female  male = 1

• local¿ (22456 , 61088)=min ¿ = 0.43


• local_sim_EQ(22456,61088) = matric  matric = 1
• local_sim_EL(22456,61088) = good  good = 1
• local_sim_Gen(22456,61088) = male = male = 0
• local¿ (33451 ,61088)=min¿ = 0.39
• local_sim_EQ(33451,61088) = STPM  matric = 1
• local_sim_EL(33451,61088) = good = good = 0
• local_sim_Gen(33451,61088) = female  male = 1

• local¿ (23849 , 61088)=min ¿ = 0.11


• local_sim_EQ(23849,61088) = diploma  matric = 1
• local_sim_EL(23849,61088) = moderate  good = 1
• local_sim_Gen(23849,61088) = emale f male = 1

Compute global similarities (equal weightage):


• global¿ (22619,61088)=¿
• global¿ (22417,61088)=¿
• global¿ (22353,61088)=¿
• global¿ (22456,61088)=¿
• global¿ (33451,61088)=¿
• global¿ (23849,61088)=¿

Decision: Working as previous similar record is 22619 with 86 % chance of similarity :


working

For Matric : 31752

Compute all local similarities:


• local¿ (22619 , 31752)=min¿ = 0.19
• local_sim_EQ(22619,31752) = matric  STPM = 1
• local_sim_EL(22619,31752) = good  poor = 1
• local_sim_Gen(22619,31752) = male  female = 1

• local¿ (22417 , 31752)=min ¿ = 0.73


• local_sim_EQ(22417,31752) = STPM = STPM = 0
• local_sim_EL(22417,31752) = good  poor = 1
• local_sim_Gen(22417,31752) = female = female = 0

• local¿ (22353 , 31752)=min¿ = 0.66


• local_sim_EQ(22353,31752) = STPM = STPM = 0
• local_sim_EL(22353,31752) = poor = poor = 0
• local_sim_Gen(22353,31752) = female = female = 0

• local¿ (22456 , 31752)=min ¿ = 1


• local_sim_EQ(22456,31752) = diploma  STPM = 1
• local_sim_EL(22456,31752) = poor = poor = 0
• local_sim_Gen(22456,31752) = male  female = 1

• local¿ (33451 ,31752)=min ¿ = 1


• local_sim_EQ(33451,31752) = STPM = STPM = 0
• local_sim_EL(33451,31752) = good  poor = 1
• local_sim_Gen(33451,31752) = emale =f female = 0

• local¿ (23849 , 31752)=min¿ = 0.33


• local_sim_EQ(23849,31752) = diploma  STPM = 1
• local_sim_EL(23849,31752) = moderate  poor = 1
• local_sim_Gen(23849,31752) = female = female = 0

• local¿ (61088 , 31752)=min¿ = 0.75


• local_sim_EQ(61088,31752) = matric  STPM = 1
• local_sim_EL(61088,31752) = good  poor = 1
• local_sim_Gen(61088,31752) = male  female = 1

Compute global similarities (equal weightage):


• global¿ (22619 ,31752)=¿
• global¿ ( 22417,31752)=¿
• global¿ ( 22353,31752)=¿
• global¿ ( 22456,31752)=¿
• global¿ ( 33 451,31752)=¿
• global¿ ( 23849,31752)=¿
• global¿ ( 61088 ,31752)=¿
Decision: Unemployed as previous similar record is 22353 with 84 % chance of
similarity : unemployed

3) Neural Networks (Use the given Python codes to produce this solution)
(hint: try to use learning rate, α = 0.1, momentum rate, ŋ = 0.9 with epochs ≥ 3,000 iteration and
error term ≤ 0.01)

import math
import random
import sys

# Inputs for Example 1


INPUTS = [0, 1, 3.5, 0] # (Gender, Entry Qualification, CGPA, English level)

X1 = [[1, 0, 3.67, 1],


[0, -1, 3.00, 0],
[0, -1, 3.10, -1],
[1, 1, 2.45, -1],
[0, -1, 2.51, 1]]

X2 = [[0, 1, 3.5, 0],


[1, 0, 2.98, 1],
[0, -1, 3.9, -1]]

TARGET_VALUE1 = [-1, 0, 1, 0, -1]


TARGET_VALUE2 = [0, -1, 1]

ALPHA = 0.1
MU = 0.9

N=4

M=4
NUM_CASES = 5
TEST_CASES = 3

class Frenz2:
def __init__(self, inputArray, x1, x2, target1, target2, alpha, mu, n, m, numCases, numTests):
self.mInputArray = inputArray
self.mX1 = x1
self.mX2 = x2
self.mTarget1 = target1
self.mTarget2 = target2
self.mAlpha = alpha
self.mMu = mu
self.mN = n
self.mM = m
self.mNumCases = numCases
self.mNumTests = numTests

self.hbias = [] # 'h' refers to the hidden layer.


self.hweight = []
self.obias = 0.0 # 'o' refers to the output layer.
self.oweight = []

self.hbias2 = [] # '2' refers to training copies.


self.hweight2 = []
self.obias2 = 0.0
self.oweight2 = []

self.hin = []
self.hout = []

self.oin = 0.0
self.oout = 0.0

self.inputNeuron = []
return

def initialize_arrays(self):

for i in range(self.mN):
self.hweight.append([0.0] * self.mM)
self.hweight2.append([0.0] * self.mM)
for j in range(self.mM):
self.hweight[i][j] = random.random() - 0.5 # hidden layer connections.
self.hweight2[i][j] = self.hweight[i][j] # copies for training.

for j in range(self.mM):
self.hbias.append(random.random() - 0.5) # hidden layer biases.
self.hbias2.append(self.hbias[j]) # copies for training.
self.oweight.append(random.random() - 0.5) # output layer connections.
self.oweight2.append(self.oweight[j]) # copies for training.

self.obias = random.random() - 0.5 # output neuron bias.


self.obias2 = self.obias # copy for training.

self.hin = [0.0] * self.mM


self.hout = [0.0] * self.mM
self.inputNeuron = [0.0] * self.mN

return

def sigmoid(self, val):

return (2.0 / (1.0 + (math.exp(-val)))) - 1.0 # Output ranges from -1 to 1.

def sigmoid_derivative(self, val):

return (1.0 / 2.0) * (1.0 + self.sigmoid(val)) * (1.0 - self.sigmoid(val))

def round(self, floatInput):


floatOutput = 0.0

if floatInput > 0.5:


floatOutput = float(math.ceil(floatInput))
elif floatInput < -0.5:
floatOutput = float(math.floor(floatInput))
else:
floatOutput = 0.0

return floatOutput

def hidden_input(self, n, m):

total = 0.0
for j in range(m):
total = 0
for i in range(n):
total += (self.inputNeuron[i] * self.hweight[i][j])

self.hin[j] = self.hbias[j] + total

for j in range(m):
self.hout[j] = self.sigmoid(self.hin[j])

return

def output_input(self, m):


total = 0.0

for j in range(m):
total += (self.hout[j] * self.oweight[j])

self.oin = self.obias + total


return

def update_hidden(self, n, m, d):


hdelta = 0.0
dhbias = [0.0] * m
dhweight = []
for i in range(n):
dhweight.append([0.0] * m)

for j in range(m):
hdelta = (d * self.oweight[j]) * self.sigmoid_derivative(self.hin[j])

for i in range(n):
dhweight[i][j] = (self.mAlpha * hdelta * self.inputNeuron[i]) + (self.mMu * (self.hweight[i][j] -
self.hweight2[i][j]))
self.hweight2[i][j] = self.hweight[i][j]
self.hweight[i][j] += dhweight[i][j]

dhbias[j] = (self.mAlpha * hdelta) + (self.mMu * (self.hbias[j] - self.hbias2[j]))


self.hbias2[j] = self.hbias[j]
self.hbias[j] += dhbias[j]

return

def backpropagate(self, i, m):


odelta = self.sigmoid_derivative(self.oin) * (self.mTarget1[i] - self.oout)
dobias = 0.0
doweight = [0.0] * m

for j in range(m):
doweight[j] = (self.mAlpha * odelta * self.hout[j]) + (self.mMu * (self.oweight[j] -
self.oweight2[j]))
self.oweight2[j] = self.oweight[j]
self.oweight[j] += doweight[j]

dobias = (self.mAlpha * odelta) + (self.mMu * (self.obias - self.obias2))


self.obias2 = self.obias
self.obias += dobias

self.update_hidden(self.mN, m, odelta)
return

def train_network(self):
trainError = 0.0
j=0
trainingCycles = 0
trainingComplete = False

while j < 20000:


trainError = 0
for i in range(self.mNumCases):
for k in range(self.mN):
self.inputNeuron[k] = math.floor(self.mX1[i][k])

self.hidden_input(self.mN, self.mM)

self.output_input(self.mM)

self.oout = self.sigmoid(self.oin)
self.backpropagate(i, self.mM)

if j > 999:
if math.fmod(j, 1000) == 0:
sys.stdout.write(str(j) + " " + str(i) + " Expected: " + str(self.mTarget1[i]) + " Actual: " +
str(self.oout) + "\n")

trainError += math.pow((self.mTarget1[i] - self.oout), 2)

trainError = math.sqrt(trainError / float(self.mNumCases))

# Display training error level every thousand epochs.


if j > 999:
if math.fmod(j, 1000) == 0:
sys.stdout.write("Training Error: " + str(trainError) + "\n\n")

if trainError < 0.01:


if trainingComplete == False:
trainingCycles = j
trainingComplete = True

j += 1

sys.stdout.write("Training iterations needed: " + str(trainingCycles) + "\n")


return

def examine_status(self):
self.inputNeuron[0] = self.mInputArray[0] # Gender.
self.inputNeuron[1] = self.mInputArray[1] # Entry Qualification.
self.inputNeuron[2] = self.mInputArray[2] # CGPA.
self.inputNeuron[3] = self.mInputArray[3] # English level.

self.hidden_input(self.mN, self.mM)
self.output_input(self.mM)
self.oout = self.sigmoid(self.oin)

if self.oout < 0:
sys.stdout.write("\nThe graduate student will working\n\n")
else:
sys.stdout.write("\nThe graduate student will unemployed\n\n")

return

def validate_net(self):
correct = 0
sys.stdout.write("Validating network training...\n")

for i in range(self.mNumTests):
for k in range(self.mN):
self.inputNeuron[k] = math.floor(self.mX2[i][k])

self.hidden_input(self.mN, self.mM)
self.output_input(self.mM)
self.oout = self.sigmoid(self.oin)

if self.mTarget2[i] == self.round(self.oout):
correct += 1

sys.stdout.write("Expected: " + str(self.mTarget2[i]) + " Actual: " + str(self.round(self.oout)) +


"\n")

if correct >= 2:
sys.stdout.write(str(correct) + " out of " + str(self.mNumTests) + " Match. Validation
Successful.\n")
else:
sys.stdout.write(str(correct) + " out of " + str(self.mNumTests) + " Match. Validation
Unsuccessful.\n")

return

if __name__ == '__main__':
f2 = Frenz2(INPUTS, X1, X2, TARGET_VALUE1, TARGET_VALUE2, ALPHA, MU, N, M,
NUM_CASES, TEST_CASES)
f2.initialize_arrays()
f2.train_network()
f2.examine_status()
f2.validate_net()

Output:
1000 0 Expected: -1 Actual: -0.9954680265524264
1000 1 Expected: 0 Actual: 0.036856967502504334
1000 2 Expected: 1 Actual: 0.9823421617889561
1000 3 Expected: 0 Actual: 0.004714383403897848
1000 4 Expected: -1 Actual: -0.988105926056622
Training Error: 0.01925860063943935

2000 0 Expected: -1 Actual: -0.9970461714438666


2000 1 Expected: 0 Actual: 8.967697984418876e-05
2000 2 Expected: 1 Actual: 0.9876567871514372
2000 3 Expected: 0 Actual: 7.032858933220254e-05
2000 4 Expected: -1 Actual: -0.9919474359389124
Training Error: 0.006722154157605497

3000 0 Expected: -1 Actual: -0.9976437931494959


3000 1 Expected: 0 Actual: 4.601150167382606e-05
3000 2 Expected: 1 Actual: 0.9897528025925031
3000 3 Expected: 0 Actual: 4.786447850801956e-05
3000 4 Expected: -1 Actual: -0.9934846898501678
Training Error: 0.0055319153978648184

4000 0 Expected: -1 Actual: -0.9979853356447469


4000 1 Expected: 0 Actual: 3.757088407341236e-05
4000 2 Expected: 1 Actual: 0.99085813487589
4000 3 Expected: 0 Actual: 3.928740112812967e-05
4000 4 Expected: -1 Actual: -0.9943487269679747
Training Error: 0.004890243600587998
5000 0 Expected: -1 Actual: -0.9984003815222381
5000 1 Expected: 0 Actual: -0.00043622556172706606
5000 2 Expected: 1 Actual: 0.9931497261931732
5000 3 Expected: 0 Actual: 3.052358550581502e-05
5000 4 Expected: -1 Actual: -0.9954500663160639
Training Error: 0.0037517502971569656

6000 0 Expected: -1 Actual: -0.9984785873220601


6000 1 Expected: 0 Actual: 2.0530482474301337e-05
6000 2 Expected: 1 Actual: 0.9929904940425436
6000 3 Expected: 0 Actual: 2.3469382180341114e-05
6000 4 Expected: -1 Actual: -0.995615217563066
Training Error: 0.0037596584854496687

7000 0 Expected: -1 Actual: -0.9986779180869224


7000 1 Expected: 0 Actual: 1.3038495930484117e-05
7000 2 Expected: 1 Actual: 0.9940913378464447
7000 3 Expected: 0 Actual: 1.6448564834625756e-05
7000 4 Expected: -1 Actual: -0.9961542621971161
Training Error: 0.0032078132375790084

8000 0 Expected: -1 Actual: -0.9986790638661139


8000 1 Expected: 0 Actual: 1.9863458520008592e-05
8000 2 Expected: 1 Actual: 0.993383630554457
8000 3 Expected: 0 Actual: 2.170995077555027e-05
8000 4 Expected: -1 Actual: -0.9960904862925886
Training Error: 0.0034873021153064973

9000 0 Expected: -1 Actual: -0.9988123657264353


9000 1 Expected: 0 Actual: 1.4039432212564762e-05
9000 2 Expected: 1 Actual: 0.9942127112412005
9000 3 Expected: 0 Actual: 1.6430284599744382e-05
9000 4 Expected: -1 Actual: -0.9964561929041617
Training Error: 0.0030809810819898273

10000 0 Expected: -1 Actual: -0.9989093166038963


10000 1 Expected: 0 Actual: 1.0977920690491416e-05
10000 2 Expected: 1 Actual: 0.9947478366686267
10000 3 Expected: 0 Actual: 1.3456992904892218e-05
10000 4 Expected: -1 Actual: -0.9967198708723246
Training Error: 0.002811916023980248

11000 0 Expected: -1 Actual: -0.9989825261790504


11000 1 Expected: 0 Actual: 9.250168065522146e-06
11000 2 Expected: 1 Actual: 0.9951071875170083
11000 3 Expected: 0 Actual: 1.1659782982897937e-05
11000 4 Expected: -1 Actual: -0.9969158737431255
Training Error: 0.002626287236938414

12000 0 Expected: -1 Actual: -0.999039572026146


12000 1 Expected: 0 Actual: 8.245381787341799e-06
12000 2 Expected: 1 Actual: 0.9953535121434862
12000 3 Expected: 0 Actual: 1.0529313005269714e-05
12000 4 Expected: -1 Actual: -0.9970652396554823
Training Error: 0.0024950057485383864

13000 0 Expected: -1 Actual: -0.9990867177095017


13000 1 Expected: 0 Actual: 7.574990728009823e-06
13000 2 Expected: 1 Actual: 0.9955403952980628
13000 3 Expected: 0 Actual: 9.723347934809112e-06
13000 4 Expected: -1 Actual: -0.9971868061063439
Training Error: 0.0023931723902369186

14000 0 Expected: -1 Actual: -0.9991255783962226


14000 1 Expected: 0 Actual: 7.179304304161249e-06
14000 2 Expected: 1 Actual: 0.9956739282129987
14000 3 Expected: 0 Actual: 9.184954256724609e-06
14000 4 Expected: -1 Actual: -0.9972844054780597
Training Error: 0.0023175029562366475

15000 0 Expected: -1 Actual: -0.9991586448097917


15000 1 Expected: 0 Actual: 6.941520559911041e-06
15000 2 Expected: 1 Actual: 0.9957736797796461
15000 3 Expected: 0 Actual: 8.805501254149917e-06
15000 4 Expected: -1 Actual: -0.9973656290648345
Training Error: 0.002258747312413104

16000 0 Expected: -1 Actual: -0.9991874962044635


16000 1 Expected: 0 Actual: 6.796065739500534e-06
16000 2 Expected: 1 Actual: 0.9958517015240804
16000 3 Expected: 0 Actual: 8.522878345962326e-06
16000 4 Expected: -1 Actual: -0.997435323531852
Training Error: 0.0022111638055700286

17000 0 Expected: -1 Actual: -0.9992116767422601


17000 1 Expected: 0 Actual: 6.807978287559635e-06
17000 2 Expected: 1 Actual: 0.9958958672830804
17000 3 Expected: 0 Actual: 8.38984894713235e-06
17000 4 Expected: -1 Actual: -0.997490983550756
Training Error: 0.0021799375769729584

18000 0 Expected: -1 Actual: -0.999231496924509


18000 1 Expected: 0 Actual: 6.995622461314355e-06
18000 2 Expected: 1 Actual: 0.9959035323458496
18000 3 Expected: 0 Actual: 8.416879863304416e-06
18000 4 Expected: -1 Actual: -0.9975330342566918
Training Error: 0.0021659955669297176

19000 0 Expected: -1 Actual: -0.9993019527038354


19000 1 Expected: 0 Actual: -0.027303754128294555
19000 2 Expected: 1 Actual: 0.9964530547292725
19000 3 Expected: 0 Actual: -0.0035489394563815724
19000 4 Expected: -1 Actual: -0.9977270736719981
Training Error: 0.012460531655087334

Training iterations needed: 1610


The graduate student will working
Validating network training...
Expected: 0 Actual: -1.0
Expected: -1 Actual: -1.0
Expected: 1 Actual: 1.0
2 out of 3 Match. Validation Successful.
Part B (KNIME Data Analytics Toolkit):
The goal of this part is to build predictive data analytics models using the data
in datasetAssignment2_studentAdmision.csv. This data set involves a set of criteria to select new
students into a postgraduate programme. For this task, you are required to implement three machine
algorithms (Neural Networks, Decision Tree and Support Vector Machine) to classify new cases
(datasetAssignment2_studentAdmisionPredict.csv) using KNIME data analytic toolkit.

Please turn in:


✓ The models built on the full data set.
✓ Evidence of models’ goodness (accuracy).
✓ The predictive results when the model is applied to new applicants.
✓ Solutions will be graded on completeness and comprehensibility, whether you correctly and
validly apply the method you choose to this data, and whether the methods you chose fit the
requirements of this assignment

Policy:
All grading of deliverables will be based on standards indicated for each deliverable. Deliverables may
not
be turned in late and no cheating! For the purposes of this class, cheating will include: plagiarism (using
the writings of another without proper citation), copying of another (either current or past student's
work), working with another on individually assigned work , or in any other way presenting as one's own
work that which is not entirely one's own work. The occurrence of plagiarism will result in removal from
the course with a failing grade.

You might also like