# How do I save the output to .txt file?

**URL:** <https://discourse.julialang.org/t/how-do-i-save-the-output-to-txt-file/32270>\
**Category:** General Usage\
**Tags:** question\
**Created:** [December 14, 2019, 2:30pm UTC](https://discourse.julialang.org/t/how-do-i-save-the-output-to-txt-file/32270 "2019-12-14T14:30:49Z")\
**Posts on this page:** 1\
**Showing post:** 5

<div class="post-metadata">

**Author:** ![orialb](https://avatars.discourse-cdn.com/v4/letter/o/65b543/32.png) [@orialb](https://discourse.julialang.org/u/orialb)\
**Post date:** [December 14, 2019, 3:08pm UTC](https://discourse.julialang.org/t/how-do-i-save-the-output-to-txt-file/32270/5 "2019-12-14T15:08:50Z")

</div>

Have a look at the [documentation](https://docs.julialang.org/en/v1/base/io-network/#Base.open), which you can also access from the REPL by typing `? open` and `? do`.  
If you still have questions after reading the documentation feel free to ask.

Depending on what exactly it is that you do, I don’t think the optimal solution is to print the arrays into a text file like this. Maybe you can organize all your data in a [dataframe](https://juliadata.github.io/DataFrames.jl/stable/) which you can then more easily manipulate and save/load from file.

You could also use a package like [JLD2](https://github.com/JuliaIO/JLD2.jl) which allows you to save and load Julia objects in a format similar to HDF5.

---

_[View the full topic](https://discourse.julialang.org/t/how-do-i-save-the-output-to-txt-file/32270)._
