[julia-users] Re: flatten arrays

2016-03-10 Thread Tomas Lycken
No, vec doesn't help because I have an array of arrays (actually a vector of 
vectors), not a multidimensional array. (I think vec would actually be a 
noop...) 

Flatten.jl might provide some useful idioms, but my application is json 
deserializing, so I can't restrict myself to fixed-size containers. I have to 
investigate my particular needs, though - it's possible that I don't need 
infinite-depth recursion at all, in which case it might be better to just do 
something hard-coded that solves the immediate problem. 

Thanks anyway! 

// T 

[julia-users] Re: flatten arrays

2016-03-10 Thread Sheehan Olver
Can't you use vec?

vec(rand(3,3,3))  # returns a Vector of size 27

On Monday, December 31, 2012 at 5:05:42 AM UTC+11, S Wade wrote:
>
> Is there something like flatmap or flatten for arrays?
>
> thanks
> wade
>