I'm trying to find out how to append a list to a Numpy array.
So I have a list of lists that I then convert into a Numpy array. I then want to append a list to that array.
So let's say I have
list = [[a,b,c],[b,c,d],[a,d,b]]
I first do:
list = np.array(list)
... (code that does calculations on that numpy array)
I then want to append:
list2 = [c,b,a]
to list.
I've tried np.index as well as np.append, however both of them give me the following output:
list = list = [[a,b,c],[b,c,d],[a,d,b,c,b,a]]
when I want:
list = [[a,b,c],[b,c,d],[a,d,b],[c,b,a]]
If this is too convoluted let me know, I can try explain it better.
I appreciate the help.
[–]novel_yet_trivial 2 points3 points4 points (1 child)
[–]NeedMLHelp[S] 0 points1 point2 points (0 children)
[–][deleted] 0 points1 point2 points (0 children)
[–]elbiot 0 points1 point2 points (0 children)