print formating for matrix/table
vincent at vincentdavis.net
Tue Jan 27 03:53:39 CET 2009
I called it a matrix mostly because this is how I am visualizing it. They
are full of numbers but only as representatives of students and schools. It
looks like pprint will work after I read the instructions. At least I know
where to look now. In the end I need to figure out how to save the data a
csv formated for excel but that is for later I was just trying to make
it easier to debug my code.
On Mon, Jan 26, 2009 at 7:03 PM, Robert Kern <robert.kern at gmail.com> wrote:
> On 2009-01-26 19:53, Vincent Davis wrote:
>> I do have numpy but am using lists as did not need any functions of
>> array. Well maybe print now. I am new to python and don't really know
>> the details about the difference between lists and arrays. I do know
>> that there are different/additional functions available for arrays.
> Python lists are one-dimensional, appendable sequences of heterogeneous
> Python objects. numpy arrays are multi-dimensional, non-appendable
> containers usually of homogeneously-typed numerical data (but can also
> contain heterogeneous Python objects, too). numpy arrays have many
> conveniences over lists of lists if you need to do math on bunches of
> Anyway is this the best solution, convert the list to an array before
> I wouldn't use numpy *just* for this, but I suspect that you could actually
> use numpy for other things if you are actually using your lists of lists as
> Robert Kern
> "I have come to believe that the whole world is an enigma, a harmless
> that is made terrible by our own mad attempt to interpret it as though it
> an underlying truth."
> -- Umberto Eco
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Python-list