STUCK: trouble with step sequencers random on/off note input

pfke's icon

Hello fellow forumers,

I seek your guidance on how to make this god damn thing work.

Basically, what i have now, is a step sequencer, in which i can enable certain steps to be processed by random, so i can select which steps out of 16 will be available for random step on/off process.

Max Patch
Copy patch and select New From Clipboard in Max.

That works fine. The thing that kept me busy for few weeks now, is: how to make it, so out of all of those steps , which are enabled for random step input, only a certain ammount of them are actually being iserted. So, basically, i want to control the ammount of steps that are being inputed throughout those 16 steps. I hope it makes sence, here is my patch:

I hope you guys understand my issue, and can help me out.

cheers,