pdistmex - Error - Undefined function 'pdistmex' for input arguments of type 'double'.

Hello,
I have got the following problem. The function pdist(X,dist) gives me the following error.
"Undefined function 'pdistmex' for input arguments of type 'double'."
I dont understand why it does not work, because X is always a 'double' or isnt it?
The following lines are the code from the MatLab function pdist(X,dist).
% Call a mex file to compute distances for the standard distance measures
% and full real double or single data.
if ~strcmp(dist,'usr') && (isfloat(X) && ~issparse(X)) % ~usr => ~complex
additionalArg = cast(additionalArg,class(X));
% Here is the error.
Y = pdistmex(X',dist,additionalArg)
elseif ~strcmp(dist,'usr') && isfloat(X) % ~usr => ~complex
additionalArg = cast(additionalArg,class(X));
Y = pdistSparse(X', dist, additionalArg);

回答 (1 件)

Sahithi Kanumarlapudi
Sahithi Kanumarlapudi 2019 年 10 月 31 日
編集済み: Sahithi Kanumarlapudi 2019 年 10 月 31 日
Hello,
You usually get this error if don’t have license to the required toolbox. Ensure that you have license to ‘Statistics and Machine Learning Toolbox’.
If you have a valid license and still you are getting the error then run the following commands
toolboxcache
rehash toolboxcache
The following link shows the common errors and reasons while running functions
Hope this helps!

カテゴリ

ヘルプ センター および File ExchangeMATLAB についてさらに検索

質問済み:

2019 年 10 月 24 日

編集済み:

2019 年 10 月 31 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by