Why can't we continue writing small scripts in the MATLAB terminal as we can do in python terminal?

조회 수: 1 (최근 30일)
When we use IDE or Terminal of python we can go on to write functions or class definition there but we can't do the same on MATLAB terminal. What is the specific reason behind it?

답변 (1개)

Raghunandan V
Raghunandan V 2019년 3월 11일
I am not really sure of this answer but I will just go ahead.
In Matlab for a function to work you should create same file name as the function name. when you call this function it searches for the file name and then executes the function. If the function is defined in the terminal itself then this method will not work. I am not sure how it happens in Python. This is more in the architecture level design. If you compare these two in this way it would be like comparing apple with an orange which is not a valid comparision
I would also make a note that Python is an open source and hence we can have out own libraries and install them. I Matlab the concept of library effectively means there is a *.m file and it searches in all its part.
  댓글 수: 1
Abhishek Singh
Abhishek Singh 2019년 3월 11일
Thanks for your input but I wanted a more meaningful difference between them even if it an apple and orange comparison. Precisely, I wanted to know about how both of them actually work at the lower level.

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Call Python from MATLAB에 대해 자세히 알아보기

태그

제품


릴리스

R2018b

Community Treasure Hunt

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

Start Hunting!

Translated by