New Members: Be sure to confirm your email address by clicking on the link that was sent to your email inbox. You will not be able to post messages until you click that link.


Hi, Is there any way either with a custom index or some function in stockcharts to do the following
(BRK/B*1500) - BRK/A
This would allow me to chart the premium/discount of the BRK A to B Stock.



  • lmkwinlmkwin ✭✭
    Just some thoughts

    I would try something like creating a chartlist that has both symbols in it. And then use the rank by PctRelative

    [favorites list is 1] // Berkshire Test List

    rank by [PctRelative(20,BRK/A)]

    Or you could set up Alerts or scans with the same chartlist as the universe and the criteria would be

    and [PctRelative(20,BRK/A) > 0] //to catch the Premium

    another alert/scan with

    and [PctRelative(20,BRK/A) < 0] //to catch the Discount

    I just used 20 as an example. You could use shorter or longer periods.

    Or put them in a Perf Chart to see which is outperforming the other over time periods.

    You could also put the relationship in a chart symbol/ parameter of BRK/A:BRK/B a rising line is A outperformance, falling line is B outperformance.

  • One other way would be to maintain the data yourself on an Excel spreadsheet and upload it as a user defined index:
  • Thanks!! I know how I to do the Perf Chart and the scans and that's a great idea. How do I do the rank by PctRelative?
  • lmkwinlmkwin ✭✭
    edited April 17
    This is the Rank By example.

    [favorites list is 1] // Berkshire Test List

    rank by [PctRelative(20,BRK/A)]

    You use Rank By as the last line of a scan to both, change the results returned in a sorted order, and to get an additional piece of data to show in the results page last column.

    IF you don't see the results of the Rank By in the last column, the syntax of the Rank By line isn't accepted (most likely wrong syntax)

    Link below talks about Reordering a ChartList using Rank By.

    Rank By defaults to Descending order. If you want it to show the results in Ascending order you can either put ascending in the Rank By line

    rank by [PctRelative(20,BRK/A)] ascending

    or you can click on the PctRelative column (in this example) to change from ascending to descending and back again if needed

    I'd avoid the User Defined Index unless you are planning to be diligent in creating the spreadsheet data and keeping it current.

Sign In or Register to comment.