2015-10-22 140 views
1

我試着按照使用localfunctions函數的建議from the docs。當我在MATLAB命令窗口中執行腳本它提供了以下錯誤:Matlab`localfunctions`函數未定義

>> athing() 
Undefined function or variable 'localfunctions'. 

Error in athing (line 2) 
    fs = localfunctions; 

在文件thing.m我已經寫:

function fs = athing() 
    fs = localfunctions; 
end 

function babo() 
end 

function hidden() 
end 

我不知道還有什麼我可以試着調試這個。我正在使用MATLAB:8.0.0.783(R2012b)。

回答

6

localfunctions僅在R2013b中引入。您需要將您的MATLAB版本升級到R2013b或更新版本才能使用它。


在Mathworks網站上的所有函數參考文檔的底部是一個註釋,指出它被引入的版本。

                            enter image description here

+0

這是偉大的。非常感謝。 – Quatermain