Investment rules, margin, and market volatility