From: Christopher B. <Chr...@no...> - 2006-06-01 18:32:16
|
I want to take two (2,) arrays and put them together into one (2,2) array. I thought one of these would work: >>> N.concatenate(((1,2),(3,4)),0) array([1, 2, 3, 4]) >>> N.concatenate(((1,2),(3,4)),1) array([1, 2, 3, 4]) Is this the best I can do? >>> N.concatenate(((1,2),(3,4))).reshape(2,2) array([[1, 2], [3, 4]]) Is it because the arrays I'm putting together are rank-1? >>> N.__version__ '0.9.6' -Chris -- Christopher Barker, Ph.D. Oceanographer NOAA/OR&R/HAZMAT (206) 526-6959 voice 7600 Sand Point Way NE (206) 526-6329 fax Seattle, WA 98115 (206) 526-6317 main reception Chr...@no... |