# Save benchmark results

**URL:** https://discourse.julialang.org/t/save-benchmark-results/8514
**Category:** New to Julia
**Created:** [January 22, 2018, 2:09am UTC](https://discourse.julialang.org/t/save-benchmark-results/8514 "2018-01-22T02:09:00Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![tk3369](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tk3369/32/2824_2.png) [@tk3369](https://discourse.julialang.org/u/tk3369)
#### Post date: [January 22, 2018, 2:09am UTC](https://discourse.julialang.org/t/save-benchmark-results/8514/1 "2018-01-22T02:09:00Z")

</div>

How do I save benchmark results from BenchmarkTools? In the REPL, just typing the variable gives a nice looking report. If I try to output to a file (using println or show), it gives the short single-line form…

```julia
julia> b
BenchmarkTools.Trial: 
  memory estimate: 153.16 MiB
  allocs estimate: 1002737
  --------------
  minimum time: 164.029 ms (5.97% GC)
  median time: 266.091 ms (40.97% GC)
  mean time: 262.904 ms (32.59% GC)
  maximum time: 411.212 ms (45.30% GC)
  --------------
  samples: 5
  evals/sample: 1

julia> show(b)
Trial(164.029 ms)

```

---

<div class="post-metadata">

### Author: ![Ralph\_Smith](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ralph_smith/32/10344_2.png) [@Ralph\_Smith](https://discourse.julialang.org/u/Ralph_Smith)
#### Post date: [January 22, 2018, 2:19am UTC](https://discourse.julialang.org/t/save-benchmark-results/8514/2 "2018-01-22T02:19:05Z")

</div>

The REPL display is apparently equivalent to

```julia
show(STDOUT,MIME"text/plain"(),b)

```

which should generalize to other files.
