I have four dictionaries. And each value for each of the key in the dictionary is a 1D numpy array. I want to join all those numpy arrays into one. For example:
first dictionary = {'feature1': array([0., 0., 1., 0.]),
'feature2': array([0., 1., 0., 0.]),
'feature3': array([1., 0., 0.,0.,0.,0.])}
second dictionary = {'feature4': array([0.]),
'feature5': array([0., 0.]),
'feature6': array([0.023]),
'feature7': array([0.009]),
'feature8': array([0.])}
third dictionary = {'feature9': array([ 0., 0., 0., 912., 0., 0., 0.]),
'feature10': array([0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.]),}
The resultant final numpy should look like:
array([0., 0., 1., 0.,0., 1., 0., 0.,1., 0., 0.,0.,0.,0.,
0.,0., 0.,0.023,0.009,0.,0.,
0., 0., 912., 0., 0., 0.,0., 0., 0., 0.,
0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.]
As an example I've made this dictionaries smaller but I have unto 50 keys in each of the dictionaries. So basically I want to join all of the numpy arrays in my dictionaries. How can I achieve this? Insights will be appreciated.