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.

Breadth Thrust Alert

Hi guys,

I'd like to create a 5 day breadth thrust alert using stockcharts if possible. The formula would look something like this:

[[!ADVNYA + !ADVNYA 1 day ago + !ADVNYA 2 days ago + !ADVNYA 3 days ago + !ADVNYA 4 days ago] / [[!ADVNYA + !ADVNYA 1 day ago + !ADVNYA 2 days ago + !ADVNYA 3 days ago + !ADVNYA 4 days ago] + [!DECLNYA + !DECLNYA 1 day ago + !DECLNYA 2 days ago + !DECLNYA 3 days ago + !DECLNYA 4 days ago]]] * 100 > 73.61

...and I would be alerted when these conditions are met

but my syntax isn't correct here...

is the formula I'm suggesting possible in stockcharts?

Thanks in advance

Comments

  • I think I solved my own question in 2 lines of code

    [symbol is '$NYAD']
    and [sma(5, close)> 2432]
  • or maybe

    [symbol is '!ADVNYA']
    and [sma(5, close)> 2432]

    assuming total issues on the NYSE is 3302
  • The scan engine is designed to return symbols, not numbers, so your first attempt won't work.

    The second and third attempts will run and will return $NYAD or !ADVNYA if true.

    I'm assuming the 2432 represents the number of issues that is the target per cent of total issues (73.61?).

    That number might or might not be useful for a couple of reasons - the number of issues on the exchange varies over time as new issues are added and others delisted. Also, not every issue trades everyday.

    You could choose a number by charting the !ADVNYA with it 5 MA, then see what level meaningful peaks generally cross and use that number as a threshold. It looks to me like !ADVNYA's MA 5 hasn't hit 2400+ in months.
  • ^ very helpful, thank you. You're right, it would be significant if it did tomorrow I think
Sign In or Register to comment.