stdev = 3
value_1 = array
value_2 = array
value_3 = array
for h in range(1,4):
name = ('value' + str(h))
globals()['new_name_'+ str(h)] = np.mean(name) * stdev
It should give something like this:
new_name_1 = #result1
new_name_2 = #result2
new_name_3 = #result3
However, np.mean()
does not work with str
.
I tried to use unicode and other things.
I have to get the results(new name)
by using globals()
. Does somebody know how to do it?