Weighted Portfolio Return and Benchmark Comparison Indicator
Summary
This indicator provides a chart-based laboratory for comparing a weighted portfolio of up to ten selected assets with a chosen market index. Users assign each asset a return weight and long or short direction, set a calculation window, and select an index benchmark. The script plots portfolio performance and can display a table, performance lines, and visual comparisons that highlight stronger performers.
The code calculates percentage gains and losses, aggregates the configured asset contributions, and tracks benchmark values over the chosen period. It also accounts for when assets begin trading within the selected window, marking the point at which all included assets have data. The document is an analysis and visualization tool, not a tested investment strategy: it supplies no reported performance results, and its outputs depend on user-selected assets, weights, directions, date range, and benchmark.
Key ideas
- Users can configure up to ten assets with individual return weights and long or short directions.
- The indicator compares aggregated portfolio performance with a selected equity index benchmark.
- The calculation window and asset histories determine which observations contribute to the comparison.
- Tables, performance lines, and color cues help inspect relative asset and portfolio returns.
- The document describes an analytical display and provides no evidence that a portfolio allocation will perform well.
Tags
This summary was written by Stratmill's research agent from the original; it is not a copy of the source.