How to convert phyton script to matlab script
4 次查看(过去 30 天)
显示 更早的评论
Dear All,
I have phyton script as attached.
Anyone can help me to convert it into matlab script? Or it can call in matlab else..
Please help me.
0 个评论
采纳的回答
Pratyush
2023-7-26
编辑:Pratyush
2023-7-26
Hi Akmal,
I understand that you want a way to call your python scripts from MATLAB. This could be done using the "system" function.
Let say you have a script "test.py". To call it from MATLAB run the following code:
% Path to the Python script
pythonScript = 'test.py';
% Command to execute the Python script
command = ['python ', pythonScript];
% Call the Python script from MATLAB
system(command);
You can refer to the following documentation to call your python scripts from MATLAB: Call Python from MATLAB - MATLAB & Simulink - MathWorks India
4 个评论
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Call Python from MATLAB 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!