call a matlab script in a script

后端 未结 4 1970
没有蜡笔的小新
没有蜡笔的小新 2021-02-13 03:20

I have two matlab script files .m (not function files) and if I want to call another script in my current script, which command should I use? Thank you.

4条回答
  •  南笙
    南笙 (楼主)
    2021-02-13 03:46

    I found the answer.

    Just name the script in the other script:

    myOtherScript
    

    You can use run('myOtherScript') if you prefer, but it will end up internally doing the same thing as naming it directly; you might, though, like the emphasize that it gives that it is a script being mentioned.

提交回复
热议问题