这是很基本的,但我似乎无法在网上找到答案......如何将数据输入到训练的神经网络算法 - MATLAB
我已经开发了使用MATLAB进行分类的神经网络。但是,我想以预期的方式向训练算法提供用于预测的新数据集。我似乎无法弄清函数myNeuralNetworkFunction(X,〜,〜)的格式。什么进入X,〜和〜?如果我把这三个点的随机数值,即。 myNeuralNetworkFunction(1,2,3),它会输出
ANS =
0.4793
0.3524
0.1683
是此分别III类解释为样品装配到I类,II类的概率,和?
谢谢你的帮助,我知道这些都是新手问题。
下面是神经网络的代码:关于神经网络
function [Y,Xf,Af] = myNeuralNetworkFunction(X,~,~)
%MYNEURALNETWORKFUNCTION neural network simulation function.
%
% Generated by Neural Network Toolbox function genFunction, 25-Sep-2014 13:48:20.
%
% [Y] = myNeuralNetworkFunction(X,~,~) takes these arguments:
%
% X = 1xTS cell, 1 inputs over TS timsteps
% Each X{1,ts} = 24xQ matrix, input #1 at timestep ts.
%
% and returns:
% Y = 1xTS cell of 1 outputs over TS timesteps.
% Each Y{1,ts} = 3xQ matrix, output #1 at timestep ts.
%
% where Q is number of samples (or series) and TS is the number of timesteps.
%#ok
% ===== NEURAL NETWORK CONSTANTS =====
% Input 1
x1_step1_xoffset = [14.8911704312115;15.2767639519654;0.51064;1.90413;33.60375;15.43632;24.71805;0.01846;4.981;0.00033;0.22159;39.32377;19.36387;9.81086;0.22033;4.6786;14.9629;8.8028;4.74512;0.55702;660.25663;8.59155;0.37416;17.83039];
x1_step1_gain = [0.027354428009736;0.0612618147797722;0.53764452556903;0.108070429498904;0.00273415535440648;0.0167784432574442;0.00143874231937304;0.483828047511914;0.499625281039221;0.652986597450087;1.59790355054169;0.00545387219881284;0.018425510635389;0.00896113957019686;0.837910418997105;0.00686875293360145;0.00614397382765453;0.0196487182502502;0.10665671204021;1.48306341579166;0.000773677797796089;0.0480697241735192;0.314333448065042;0.00523034792222075];
x1_step1_ymin = -1;
% Layer 1
b1 = [1.55987050956456;1.3844896446184087;1.1858356678234501;-1.0437094397090567;-0.7695743943051927;0.7727728185085837;-0.49850097623420581;0.3360196027312633;-0.5052450230407648;0.12573629438984127;-0.36142377450191465;-0.26512162787695787;0.43422049198818885;-0.59484996326687367;-0.74347840297622803;-1.1241254208475855;1.0621269773342072;-1.1217914200306649;1.4625923192101142;-1.5876844882508814];
IW1_1 = [-0.055982436209679104 -0.28944502014743512 0.38896483763687473 -0.17520091781902516 -0.36788963119290879 0.58680010891648471 0.38941048594029137 0.010330200046712359 -0.049196997026008424 -0.25965095783883646 -0.02330444839336468 0.48471956663410432 0.35540617499483801 -0.34500146111020641 -0.0306422432801076 -0.20558648541285637 -0.48852403830931596 0.58018036801883965 -0.21778584198672668 -0.17639473933123317 -0.12894993242501401 -0.32191664913965018 0.36502076112253562 -0.35423424394067804;-0.44842057227554855 0.39700388069390274 0.18239852514402061 0.33330369404033905 -0.33083266709586073 -0.42109550142439961 -0.37936412673907055 0.1409