Javascript Loop Through Object Array Creation Numpy