how to run an m.file by another m.file ?

Hi all
is creating the function the only way to run an m file by another m file ? cause I did not want to get an output or give it an input , cause the main m file is already writing the outputs to a text file

 채택된 답변

KL
KL 2015년 4월 11일
편집: KL 2015년 4월 11일

4 개 추천

You just need to write the file name on the specific line of your program and make sure the other file exist in the same directory if not go with the absolute path.

댓글 수: 4

farzad
farzad 2015년 4월 11일
name.m you mean ?
KL
KL 2015년 4월 11일
if name.m exist in the same directory and if you want to call this file in name2.m, then just type 'name;' inside name2.m, no extension is needed!
shihabsat
shihabsat 2018년 5월 11일
Thank you very much
suman jain
suman jain 2019년 2월 3일
thanks

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

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 File Operations에 대해 자세히 알아보기

질문:

2015년 4월 11일

댓글:

2019년 2월 3일

Community Treasure Hunt

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

Start Hunting!

Translated by