声振论坛

 找回密码
 我要加入

QQ登录

只需一步,快速开始

查看: 8131|回复: 4

[编程技巧] Warning: NEWFF used in an obsolete way 如何解决

[复制链接]
发表于 2008-4-25 21:39 | 显示全部楼层 |阅读模式

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有账号?我要加入

x
>> p=[0 0 1 1;0 1 0 1]
p =
     0     0     1     1
     0     1     0     1
>> t = [1,0,0,1]
t =
     1     0     0     1
>> net=newff(minmax(p),[2,1],{'tansig','purelin'},'trainlm');
Warning: NEWFF used in an obsolete way.
> In nntobsu at 18
  In newff at 86
          See help for NEWFF to update calls to the new argument list.

>> [net,tr]=train(net,p,t);
>> a =sim(net,p)
a =
    1.0000    0.0000   -0.0000    1.0000
初学,向各位学长请教,在matlabR2008中,上边的这个警告是怎么回事??谢谢!

[ 本帖最后由 eight 于 2008-4-28 17:16 编辑 ]
回复
分享到:

使用道具 举报

发表于 2008-4-25 22:14 | 显示全部楼层
原帖由 selfcherish 于 2008-4-25 21:39 发表
>> p=[0 0 1 1;0 1 0 1]
p =
     0     0     1     1
     0     1     0     1
>> t = [1,0,0,1]
t =
     1     0     0     1
>> net=newff(minmax(p),[2,1],{'tansig','purelin'},'trainlm');
Warning ...


大概是代码net=newff(minmax(p),[2,1],{'tansig','purelin'},'trainlm')中的参数格式不符合新版本的参数格式!你可以在help帮助文件里查找newff命令,重新改一下代码!
另外,按照你的代码,我做出来的结果如下:
a =
    1.0000    0.0000    0.5000    0.5000

评分

1

查看全部评分

发表于 2008-4-28 17:15 | 显示全部楼层
原帖由 selfcherish 于 2008-4-25 21:39 发表
>> p=[0 0 1 1;0 1 0 1]
p =
     0     0     1     1
     0     1     0     1
>> t = [1,0,0,1]
t =
     1     0     0     1
>> net=newff(minmax(p),[2,1],{'tansig','purelin'},'trainlm');
Warning ...
你所使用的newff调用方式过时了,其实matlab已经给出了你最有用的信息了:See help for NEWFF to update calls to the new argument list. 这个你应该能看懂吧

评分

1

查看全部评分

发表于 2012-6-29 17:27 | 显示全部楼层
谢谢分享
发表于 2012-6-29 19:34 | 显示全部楼层
help newff
您需要登录后才可以回帖 登录 | 我要加入

本版积分规则

QQ|小黑屋|Archiver|手机版|联系我们|声振论坛

GMT+8, 2024-9-21 03:23 , Processed in 0.073276 second(s), 20 queries , Gzip On.

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表