Is it possible to display a MATLAB plot in python?
이전 댓글 표시
I tried to package the following code to a python module via the Librabry Compiler (Compiler SDK):
function drawplot(x,y)
plot(x,y);
I installed the module and then tried to call the function in Python:
import PlotDrawer
myPlotter = PlotDrawer.initialize()
myPlotter = PlotDrawer.drawplot(5,5)
The import works, but I get this error:
AttributeError: module 'PlotDrawer' has no attribute 'drawplot'
When I don't use plots like in this example I don't get any errors and it works just fine. My guess is that MATLAB Library Compiler ignores functions with graphical functions in it. Is it even possible to display a MATLAB Plot in Python via the Compiler SDK?
I have the code written already in MATLAB and want to create a GUI in Python (for more flexibility and better, professional appearance). Any other approaches?
Thanks in Advance!
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Python Package Integration에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
