MIMO narxnet for future predictions. HOW!!
古いコメントを表示
Here is my problem, I have a code that is running but I'm not sure that I do understand the concept because the results don't look like what I'm expecting. Here is my code:
x = [cost(1:24,:);Tamb24(1:24,:);SOC_old24(1:3,:);P_old24(1:3,:)];
xx = cell(1,nn);
PP = cell(1,nn);
for i = 1:nn
xx{i} = x(:,i);
PP{i} = P24(1:24,i);
end
net = narxnet(1:2,1:2,5);
[Xs,Xi,Ai,Ts] = preparets(net,xx,{},PP);
net = train(net,Xs,Ts,Xi,Ai);
[Y,Xf,Af] = net(Xs,Xi,Ai);
perf = perform(net,Ts,Y);
[netc,Xic,Aic]= closeloop(net,Xf,Af);
xnew = [cost(1:24,:);Tamb24(1:24,:);SOC_old24(1:3,:);P_old24(1:3,:)];
n = 100;
xxnew = cell(1,n);
for i = 1:n
xxnew{i} = xnew(:,i);
end
y2 = netc(xxnew,Xic,Aic);
yy = cell2mat(y2);
figure(2)
plot(1:24,P24(1:24,4))
hold on
grid on
plot(1:24,yy(:,4))
legend('Measured','Model')
hold off
Sometimes I run this code and get really very good R values and the parity plot looks nice, but the plot of the predicted data vs. the actual one is really terrible! Is there something wrong with my understanding of how this should work?
1 件のコメント
Greg Heath
2018 年 5 月 1 日
LINE 6:
P24 IS UNDEFINED!
回答 (1 件)
Moataz Sheha
2018 年 4 月 30 日
0 投票
1 件のコメント
Greg Heath
2018 年 5 月 1 日
PLEASE MOVE YOUR COMMENT TO A COMMENT BOX. THEN DELETE IT FROM THE ANSWER BOX
THANKS
カテゴリ
ヘルプ センター および File Exchange で AI for Wireless についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!