arokem / python-matlab-bridge

A simple Python => MATLAB(R) interface and a matlab_magic for ipython
BSD 2-Clause "Simplified" License
332 stars 97 forks source link

macOS Monterey: Undefined function pops up when a python string is inserted as an argument. #267

Closed gaveen99 closed 2 years ago

gaveen99 commented 2 years ago

Hi there,

when I try to send a python string to the MATLAB function and it throws an error as below.

{'result': '', 'success': False, 'content': {'stdout': "Undefined function 'lib' for input arguments of type 'struct'."}}

Also, I tried converting to char and sending the argument. Unfortunately, the same error occurred.

Regards, gaveen99

arokem commented 2 years ago

Looks like maybe this is a Matlab thing? https://www.mathworks.com/matlabcentral/answers/27160-input-arguments-of-type-struct#answer_570939.

gaveen99 commented 2 years ago

Looks like maybe this is a Matlab thing? https://www.mathworks.com/matlabcentral/answers/27160-input-arguments-of-type-struct#answer_570939.

Thank you for this solution. Got the output as desired.. pymatbridge FTW 😍

gaveen99 commented 2 years ago

Hi There,

I'm getting these errors when it tries to initiate the MATLAB instance.

/Applications/MATLAB_R2022a.app/bin/matlab: line 398: awk: command not found
/Applications/MATLAB_R2022a.app/bin/matlab: line 414: expr: command not found