Filter löschen
Filter löschen

how to use pyrunfile Python inside a .m file?

3 Ansichten (letzte 30 Tage)
Nadatimuj
Nadatimuj am 4 Jun. 2022
Kommentiert: Nadatimuj am 9 Jun. 2022
I am trying to call a python script from MATLAB. It looks like pyrunfile("main.py") command works well in the command window but when I try to wrap it within a .m file, it just says " continue entering statement". How do I wrap pyrunfile command in my .m file? Thanks.
  2 Kommentare
Ayush Yadav
Ayush Yadav am 7 Jun. 2022
Hi,
I understand that you are unable to call a python script from MATLAB even though you can call it from the command line. I am unable to reproduce the error message and I can successfully run a python script using python 3.9 on MATLAB R2022a.
Can you share the python script and the .m file that you are trying to execute?
Nadatimuj
Nadatimuj am 9 Jun. 2022
It was probably some mistake by me. Sorry. It looks like it works.

Melden Sie sich an, um zu kommentieren.

Antworten (0)

Kategorien

Mehr zu Call Python from MATLAB finden Sie in Help Center und File Exchange

Tags

Produkte


Version

R2022a

Community Treasure Hunt

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

Start Hunting!

Translated by