% Load the Fisher iris dataset
load fisheriris
% Extract the input data and the targets from the dataset
[x,t] = iris_dataset;
% Create a pattern recognition network with 10 hidden neurons
net = patternnet(10);
% Extract the 3rd and 4th columns of the input data
a = x(3:4,:);
% Train the network using the input data and the targets
net = train(net,a,t);
% Use the trained network to predict the targets for the input data
j = net(a);
numRows = size(j,1);
% Find the maximum value in each column of the predicted targets
maxvals = max(j);
% Set all values in j that are not equal to the maximum value in their column to 0
j(j~=repmat(max(j),numRows,1)) = 0;
% Count the number of non-zero elements in each column of j
numNonZeroInCol = sum(j~=0);
% Count the number of non-zero elements in each row of j
numNonZeroRow = sum(j~=0,2);
% Find the row with the most non-zero elements
mostMaxIdx = find(numNonZeroRow == max(numNonZeroRow));
% Convert the predicted targets to indices
xxx = vec2ind(j);
% Create a scatter plot of the input data with the predicted targets as labels
figure
gscatter(a(1,:),a(2,:),xxx,'grb','sod')
%% 1.3
% Load the Fisher iris dataset
load fisheriris
% Extract the input data and the targets from the dataset
[x,t] = iris_dataset;
% Create a pattern recognition network with 10 hidden neurons
net = patternnet(10);
% Extract the 3rd and 4th columns of the input data
a = x(3:4,:);
% Train the network using the input data and the targets
net = train(net,a,t);
% Create a grid of points for the input data
[x,y] = meshgrid(0:0.1:7,0:0.1:4.5);
x = x(:);
y = y(:);
% Concatenate the x and y values into a single array
C = cat(2,x,y);
% Use the trained...
Šį darbą sudaro 623 žodžiai, tikrai rasi tai, ko ieškai!
★ Klientai rekomenduoja
Šį rašto darbą rekomenduoja mūsų klientai. Ką tai reiškia?
Mūsų svetainėje pateikiama dešimtys tūkstančių skirtingų rašto darbų, kuriuos įkėlė daugybė moksleivių ir studentų su skirtingais gabumais. Būtent šis rašto darbas yra patikrintas specialistų ir rekomenduojamas kitų klientų, kurie po atsisiuntimo įvertino šį mokslo darbą teigiamai. Todėl galite būti tikri, kad šis pasirinkimas geriausias!
Norint atsisiųsti šį darbą spausk ☞ Peržiūrėti darbą mygtuką!
Mūsų mokslo darbų bazėje yra daugybė įvairių mokslo darbų, todėl tikrai atrasi sau tinkamą!
Panašūs darbai
Atsisiuntei rašto darbą ir neradai jame reikalingos informacijos? Pakeisime jį kitu nemokamai.
Pirkdamas daugiau nei vieną darbą, nuo sekančių darbų gausi 25% nuolaidą.
Išsirink norimus rašto darbus ir gauk juos akimirksniu po sėkmingo apmokėjimo!