八度:从单个文件加载许多功能 [英] octave: load many functions from single file

查看:53
本文介绍了八度:从单个文件加载许多功能的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何将多个函数放在一个文件中,然后在octave解释器中访问所有这些函数?我不想拥有一千个文件,并且不想将功能分组在一起.我想要类似python中的导入"之类的东西.

How can I put multiple functions in one file and later get access to all of them in the octave interpreter ? I don't want to have a thousand files and want to group functions together. I'd like something like 'import' in python.

推荐答案

您正在寻找的被称为脚本文件",在其中定义:

What you're looking for is called "script files", defined there: http://www.gnu.org/software/octave/doc/interpreter/Script-Files.html

这篇关于八度:从单个文件加载许多功能的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆