Question: which array type is best

acer discussed in a recent post the effect of different array types on performance.

I have, however, a much more elementary question: Maple has a bewildering number of differing data structures: Arrays, Vectors, lists, sets, tables,... Some of these are supersets of others.

Being still on the learning curve I am building a module with definitions of certain functions or procedures I use frequently, such as to make my life easier. A lot of my stuff uses array-like structures filled with data, sometimes read-in via ImportMatrix. I then typically extract certain columns, process these and plot a result.

The question is then: Which Maple construct is optimal for my use. For better or worse; I have settled on making everything 1-dimensional a column Vector and everything 2-dimensional a Matrix by using either the appropriate constructor functions or angle brackets (). This appears to allow me to use functions from the LinearAlgebra package for certain operations, sometimes that is handy.

Recently, however, I bumped against a limit in Statistics:-ErrorPlot which forced me to convert a Vector into a list. While not necessarily a big problem I'd hate ending up littering my code with converts.

By my limited understanding, a list is a superset of a Vector. So should I use lists instead of vectors? Can I use LinearAlgebra functions on lists? Why the heck do we have that many structures to begin with??

Someone else must have thought about this before & maybe can share his/her experience?

TIA,

Mac Dude.

Please Wait...