How to convert phyton script to matlab script
조회 수: 7 (최근 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!