Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

append in dictionary with matrix values

import numpy as np

a = np.mat('4 3; 2 1')
b = np.mat('1 2; 3 4')
print(a)
# [[4 3]
#  [2 1]]
print(b)
# [[1 2]
#  [3 4]]
print(a*b)
# [[13 20]
#  [ 5  8]]
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #append #dictionary #matrix #values
ADD COMMENT
Topic
Name
1+9 =