Determining Optimal Trading Rules Without Backtesting