Can anybody think of an algorithm for specifying the number of trades taken over a time period. For example, let's say I want to randomly buy stocks on the close of one day and exit on the close the next day, but over a year I want my total trades to be a specific number.
The only thing I can think of would be to divide the specified number of trades per year by the population of securites multiplied by the number of bars in the trading period . Then to use something like buy=random<(calculated number) Does this sound reasonable or is there an easier way?
