I want to create fake data for four variables: Height, Weight, Age and Income.
I have use this script:
cov_matrix = [[1, 0.7, 0, 0],
[0.7, 1, 0, 0],
[0, 0, 1, 0.4],
[0, 0, 0.4, 1]]
correlated = np.random.multivariate_normal([165, 65, 30, 15000], cov_matrix, size=250)
data = pd.DataFrame({
"Height": correlated[:, 0],
"Weight": correlated[:, 1],
"Age": correlated[:, 2],
"Income": correlated[:, 3]
})
But the results are not good enough, the standard deviation (sd) of the four variables is approximately 1, and I want my data to have more dispersion. For example, being 30 the sd for the variable "Height".
Is there any possibility to achieve this in Python?