kellycriterion.com is an attempt to answer the question of how to best construct a portfolio.
It borrows heavily from Harry Markowitz's Nobel prize winning paper Portfolio Selection, except it tries to maximize for expected growth rate rather than doing Mean-Variance optimization (there's also a "Markowitz" mode in the app).
For maximizing growth rate the app uses the Kelly criterion, as first described by J. L. Kelly Jr in 1956.
Monte Carlo simulations are run where the expected return of each stock is taken from a customizable discounted cash flow model, along with its historical volatility and correlations to other stocks, to find how adding to each position would affect the growth rate of the portfolio, its return and volatility.