Thanks for the explanation!! That's exactly what I need at the moment,
though I clearly know that unpredictable return type could be dangerous.
Many thanks.
On Sunday, May 15, 2016 at 9:07:12 PM UTC+1, Kristoffer Carlsson wrote:
>
> It is possible but seems like something undesirable because
It is possible but seems like something undesirable because you then don't
know if an Array{T,1} or Array{T,2} will be returned by the function. This
is something Julia people like to call "type instability" when the type of
your returned variables depend not only on the type of the arguments
Thanks for the pointer for reshape.
Sorry that I failed to make my question clear enough. In fact, I wonder if
there is a function which can _automatically_ recast a single-column
Array{T,2} to an Array{T,1} and do nothing if this Array{T,2} has multiple
rows.
On Sunday, May 15, 2016 at
See reshape and vec.
Best,
--Tim
On Sunday, May 15, 2016 09:00:33 AM chobbes...@gmail.com wrote:
> Here is rookie question, which I have tried to find a similar question and
> answer in the history of this group, but failed. Please bear me.
>
> Since Julia distinguishes between Array{Float64,1}