When calculating standard deviation for 2 variables then i can use simple two lines to calculate weights for my variables by
import numpy as np
w1 = np.arange(0.01, 1, 0.01)
w2 = 1 - w1
and then i can just use them as pairs and I have all possible weights: [0.01, 0.99], [0.02, 0.98], ..., [0.99, 0.01]
So what would be a way to calculate weights if i have more than two variables? I tried to create it using itertools.product but for like 10 variables i took so long that i think there needs to be a better way.