use of org.ojalgo.finance.portfolio.simulator.PortfolioSimulator in project ojAlgo-finance by optimatika.
the class SimplePortfolio method getSimulator.
public PortfolioSimulator getSimulator() {
final List<GeometricBrownianMotion> tmpAssetProcesses = new ArrayList<>(myComponents.size());
for (final SimpleAsset tmpAsset : myComponents) {
final GeometricBrownianMotion tmpForecast = tmpAsset.forecast();
tmpForecast.setValue(tmpAsset.getWeight().doubleValue());
tmpAssetProcesses.add(tmpForecast);
}
return new PortfolioSimulator(myCorrelations, tmpAssetProcesses);
}
Aggregations