# Ragged Arrays

**URL:** <https://discourse.julialang.org/t/ragged-arrays/17145>\
**Category:** New to Julia\
**Created:** [November 4, 2018, 7:50pm UTC](https://discourse.julialang.org/t/ragged-arrays/17145 "2018-11-04T19:50:58Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![rveltz](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/rveltz/32/2707_2.png) [@rveltz](https://discourse.julialang.org/u/rveltz)\
**Post date:** [November 4, 2018, 7:50pm UTC](https://discourse.julialang.org/t/ragged-arrays/17145/1 "2018-11-04T19:50:58Z")

</div>

Hi,

I was wondering why the package `RaggedArrays.jl`  
has not been updated since ages. Is there a good alternative?

thanks

---

<div class="post-metadata">

**Author:** ![StefanKarpinski](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/stefankarpinski/32/24_2.png) [@StefanKarpinski](https://discourse.julialang.org/u/StefanKarpinski)\
**Post date:** [November 4, 2018, 9:54pm UTC](https://discourse.julialang.org/t/ragged-arrays/17145/2 "2018-11-04T21:54:19Z")

</div>

@mbauman would have to answer but I would imagine that it’s because there wasn’t that much demand for the functionality. I’m guessing that a vector of vectors is usually a pretty good representation of ragged array data which doesn’t require a package.

---

<div class="post-metadata">

**Author:** ![mbauman](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/mbauman/32/31082_2.png) [@mbauman](https://discourse.julialang.org/u/mbauman)\
**Post date:** [November 5, 2018, 12:13am UTC](https://discourse.julialang.org/t/ragged-arrays/17145/3 "2018-11-05T00:13:00Z")

</div>

Yeah, as I note in the first sentence of the Readme, it was predominantly an experiment to see if it was possible in the first place. The answer is kinda, but it’s awkward and there’s not much demand. Were I to do it again, I don’t think I’d make it an `AbstractArray`. You simply aren’t able to use it within generic functions since, well, the assumption that things are rectangular is so thoroughly entrenched that you don’t get much of anything for free. I managed to code it up in a way that threw errors in such cases (in some ancient version of Julia), but it really just needs a whole lot of work to re-implement lots of functions for the particular ragged structure.

You can take a look a [RecursiveArrayTools](https://github.com/JuliaDiffEq/RecursiveArrayTools.jl) to make working with vectors of vectors a bit easier.

---

<div class="post-metadata">

**Author:** ![rveltz](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/rveltz/32/2707_2.png) [@rveltz](https://discourse.julialang.org/u/rveltz)\
**Post date:** [November 5, 2018, 6:48am UTC](https://discourse.julialang.org/t/ragged-arrays/17145/4 "2018-11-05T06:48:49Z")

</div>

Hi,

Thank you for your detailed explanations.

Best,

---

<div class="post-metadata">

**Author:** ![dlfivefifty](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/dlfivefifty/32/1959_2.png) [@dlfivefifty](https://discourse.julialang.org/u/dlfivefifty)\
**Post date:** [November 6, 2018, 9:18am UTC](https://discourse.julialang.org/t/ragged-arrays/17145/5 "2018-11-06T09:18:02Z")

</div>

If you want a `RaggedMatrix` I could move it out of ApproxFun. This has a different setup as the raggedness is interpreted as a sparsity pattern: indexing out of the ragged edges gives a zero instead of a bounds error. This works better as an `AbstractMatrix`.

---

<div class="post-metadata">

**Author:** ![rveltz](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/rveltz/32/2707_2.png) [@rveltz](https://discourse.julialang.org/u/rveltz)\
**Post date:** [November 6, 2018, 3:59pm UTC](https://discourse.julialang.org/t/ragged-arrays/17145/6 "2018-11-06T15:59:07Z")

</div>

Oh…thank you very much!

It could be of interest to others than me as well. I can work without it for now though but would use it if made available.

It is up to you, you have a lot to do with `ApproxFun` already…

Best
