# Is there a way to speed up this code?

**URL:** <https://discourse.julialang.org/t/is-there-a-way-to-speed-up-this-code/102878>\
**Category:** Performance\
**Tags:** question, parsing, io\
**Created:** [August 16, 2023, 7:11pm UTC](https://discourse.julialang.org/t/is-there-a-way-to-speed-up-this-code/102878 "2023-08-16T19:11:43Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![algunion](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/algunion/32/51630_2.png) [@algunion](https://discourse.julialang.org/u/algunion)\
**Post date:** [August 16, 2023, 7:26pm UTC](https://discourse.julialang.org/t/is-there-a-way-to-speed-up-this-code/102878/2 "2023-08-16T19:26:38Z")

</div>

Hello @Luis_Manuel_Espinoza ,

You would make it easier for anybody willing to help if you would take a look at the following [guidelines](https://discourse.julialang.org/t/please-read-make-it-easier-to-help-you/14757) and provide a nicer code formatting.

One quick improvement can be the removal of allocations associated with: `coords[i, :] = [parse(Float64, d) for d in data[2:4]]` line.

A potential replacement is this:

```julia
for ii in 1:3
    coords[i, ii] = parse(Float64, data[ii+1])
end 

```

---

_[View the full topic](https://discourse.julialang.org/t/is-there-a-way-to-speed-up-this-code/102878)._
