當前位置:首頁 » 操作系統 » 蠓蟲分類演算法

蠓蟲分類演算法

發布時間: 2024-01-21 06:17:13

A. matlab中有沒有感知器演算法的函數

clear all
%輸入向量,兩種蠓蟲的特徵向量
p=[1.24 1.36 1.38 1.378 1.38 1.40 1.48 1.54 1.56 1.14 1.18 1.20 1.26 1.28 ...
1.30;1.72 1.74 1.64 1.82 1.90 1.70 1.70 1.82 2.08 1.78 1.96 1.86 2.00 2.00 1.96];
%目標向量
t=[1 1 1 1 1 1 1 1 1 0 0 0 0 0 0];
%創建感知器網路
net=newp([0 2.5;0 2.5],1);
figure;
cla;
plotpv(p,t);
plotpc(net.IW{1},net.b{1});
hold on;
%訓練該感知器網路
net=init(net);
linehandle=plotpc(net.IW{1},net.b{1});
pause
[net,y,e]=adapt(net,p,t);
linehandle=plotpc(net.IW{1},net.b{1},linehandle);
%檢驗該感知器網路
p1=[1.24 1.28 1.40;1.80 1.84 2.04];
a=sim(net,p1);
figure;
plotpv(p1,a);
Thepoint=findobj(gca,'type','line');
set(Thepoint,'color','red');
hold on;
plotpv(p,t);
plotpc(net.IW{1},net.b{1});
hold off;
pause

熱點內容
java返回this 發布:2025-10-20 08:28:16 瀏覽:570
製作腳本網站 發布:2025-10-20 08:17:34 瀏覽:858
python中的init方法 發布:2025-10-20 08:17:33 瀏覽:557
圖案密碼什麼意思 發布:2025-10-20 08:16:56 瀏覽:739
怎麼清理微信視頻緩存 發布:2025-10-20 08:12:37 瀏覽:659
c語言編譯器怎麼看執行過程 發布:2025-10-20 08:00:32 瀏覽:980
郵箱如何填寫發信伺服器 發布:2025-10-20 07:45:27 瀏覽:231
shell腳本入門案例 發布:2025-10-20 07:44:45 瀏覽:89
怎麼上傳照片瀏覽上傳 發布:2025-10-20 07:44:03 瀏覽:782
python股票數據獲取 發布:2025-10-20 07:39:44 瀏覽:686