Advertisement
subasah

create-train-test

Feb 9th, 2020
518
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
MatLab 0.25 KB | None | 0 0
  1. x = [0 1 2 3 4 5 6 7 8];
  2. t = [0 0.84 0.91 0.14 -0.77 -0.96 -0.28 0.66 0.99];
  3. plot(x,t,'o')
  4. net = feedforwardnet(10);
  5. net = configure(net,x,t);
  6. y1 = net(x);
  7. plot(x,t,'o',x,y1,'x')
  8. net = train(net,x,t);
  9. y2 = net(x);
  10. plot(x,t,'o',x,y1,'x',x,y2,'*')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement