% Download the data from the class website: load Exam2Ques2DataE %THIS IS REVISED (SLIGHTLY NEW DATA) % Plot the data for the classifier: plot(X1(:,1),X1(:,2),'r*'); hold on plot(X2(:,1),X2(:,2),'b^'); plot(X3(:,1),X3(:,2),'gs'); plot(X4(:,1),X4(:,2),'mp'); %Once you've determined your weights, put the two decision boundaries here: hold off % Create the domain data as a tall matrix, 400 x 2 X=[X1;X2;X3;X4]; % Create a tall matrix of target values for the classes, (+/-1, +/-1) tt=ones(100,1); T=[-tt tt; tt tt; tt -tt; -tt -tt]; %THIS IS REVISED %Delete this unless you want the original data around: clear X1 X2 X3 X4 tt