I have the following 1D numpy array:
li = array([ 0.002, 0.003, 0.005, 0.009])
li.shape
(4L,)
I would like to make a 2D numpy array (li_2d) with shape of (4L,5L) that looks like this:
li_2d = array([[ 0.002, 0.002, 0.002, 0.002, 0.002],
[ 0.003, 0.003, 0.003, 0.003, 0.003],
[ 0.005, 0.005, 0.005, 0.005, 0.005]
[ 0.009, 0.009, 0.009, 0.009, 0.009]])
Is there some numpy function to do that? Thank you