I would like to write a simple function to sample points from some d dimensional simplex, also specifying how many values I want to be different than zero.
For example, if d=5 and I want only two non-zero values then it could sample the points
np.array([0.,0.,0.,0.25,0.75])
np.array([0.5, 0.5, 0., 0., 0.])
np.array([0.0, 0.0, 0.8 ,0.2,0.])