in reply to using PDL->transpose on CSV file

See Two handy tools for nested arrays: mapat and transpose and Transpose a matrix of chars for some ideas. I don't think you would need the number crunching power of PDL for a simple transpose. See Math-Matrix

There are also some snippets laying around in old nodes, for taking slices from 2-d arrays, you could just take slices and use it to convert from rows to columns or vice-versa.

Here is one I have handy( use Super Search)

#!/usr/bin/perl # 2-d array-slice my @arr = (['a','b','c'], ['h','i','j'], ['x','y','z']); print map $_->[1], @arr; print "\n";

I'm not really a human, but I play one on earth. flash japh

Replies are listed 'Best First'.
Re^2: using PDL->transpose on CSV file
by bfdi533 (Friar) on Feb 08, 2006 at 21:13 UTC

    Yes, I discovered pretty quickly that PDL is not the right tool.

    However, the Transpose a matrix of chars node was exactly what I needed.

    The other one you mentioned I did eventually find but it seemed more suited to numbers and the theory/explanation was way beyond my meager understanding of that stuff.

    Thanks again for the rapid and spot-on reply.