Separate biases and weight values from weight/bias vector
[b,IW,LW] = separatewb(net,wb)
[b,IW,LW] = separatewb(net,wb) takes two arguments,
Cell array of bias vectors
Cell array of input weight matrices
Cell array of layer weight matrices
Here a feedforward network is trained to fit some data, then its bias and weight values formed into a vector. The single vector is then redivided into the original biases and weights.
[x,t] = simplefit_dataset; net = feedforwardnet(20); net = train(net,x,t); wb = formwb(net,net.b,net.iw,net.lw) [b,iw,lw] = separatewb(net,wb)