.mex file for a function

14 ビュー (過去 30 日間)
Putsandcalls
Putsandcalls 2016 年 5 月 13 日
回答済み: Walter Roberson 2016 年 5 月 13 日
Hello,
I am running into some trouble for a function given by:
function y = fyrandperm(x)
% FYRANDPERM - Shuffles elements in random order.
%
% Y = FYRANDPERM(X)
% If X is a real matrix or vector then Y contains the elements
% of X in random order. If X is a real scalar then Y contains
% 1:X in random order.
%
n = prod(size(x));
if n == 1
n = x;
x = 1:n;
end
y = fyrandperm_mex(x,rand(1,n));
I did not write this function myself and I am trying to use it but the problem is that it calls to
fyrandperm_mex
which is a .mexw64 file. I am not precisely sure what to do with this as I cant really open it on my 2015b matlab for mac. Could someone please offer some advice ? The error I am running into states: Error in fyrandperm (line 20) y = fyrandperm_mex(x,rand(1,n));
Any help would be appreciated.
Thank you

採用された回答

Walter Roberson
Walter Roberson 2016 年 5 月 13 日
You need to get a copy of fyrandperm_mex compiled for OS-X . If the source code is available, you can use the "mex" command to compile it (after you have installed and configured a compiler for your OS-X version)
mex -v fyrandperm_mex

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeIntroduction to Installation and Licensing についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by