Investment analysis for portfolio optimization