从mathematica脚本导出数据
我正在编写一个 mathematica 脚本并在 Linux 批处理 shell 中运行它。该脚本给出了一个数字列表作为结果。我想将此列表作为一个单列写入文件,不带大括号和逗号。为此,我尝试使用 Export 命令,
Export["file.txt", A1, "Table"]
但收到错误:
Export::infer:无法推断文件 test1.txt 的格式
我尝试使用其他格式,但遇到了相同的错误。 有人可以告诉我出了什么问题以及我能做什么吗?预先致谢
I am writing a mathematica script and running it in the linux batch shell. The script gives as a result a list of numbers. I would like to write this list to a file as a one single column without the braces and commas. For this, I tried to use Export comand as
Export["file.txt", A1, "Table"]
but I get the error:
Export::infer: Cannot infer format of file test1.txt
I tried with other format but i got the same error.
Could someone please tell what is wrong and what i can do? Thank beforehand
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
这:
生成一个没有大括号和逗号的单列。
This:
produces a single column without braces and commas.
据我了解,您正在尝试导出表中的文件,为什么不尝试这样的事情,
From what I understand you are trying to export the file in TABLE, why don't you try something like this ,