StockFetcher Forums · General Discussion · Change to determine angle of any sloping line<< >>Post Follow-up
Lanclos
5 posts
msg #127474
Ignore Lanclos
3/2/2016 8:14:45 PM

I would like to modify the following script that was posted here at SF to be able to calculate the slope of any indicator like OBV or MFI or AccDist - thanks in advance


set{slope2open, 10 day normslope of open}
set{slope2close, 10 day nomrslope of close}

set{radiansopen, slope2open}
set{radiansclose, slope2close}

set{atanclose, atan(radiansclose)}
set{atanopen, atan(radiansopen)}
set{hcircle, 180 / 3.14159}
set{angledegopen, atanopen * hcircle}
set{angledegclose, atanclose * hcircle}

set{angledegx, angledegopen + angledegclose}
set{angledeg2, angledegx / 2}

set{E36b,days(angledeg2 is above angledeg2 1 day ago ,100)}
set{E36a,days(angledeg2 is below angledeg2 1 day ago ,100)}
set{degreechg, E36a - E36b}

volume above 500000
degreechg above 1

and draw 10 day normslope of close
and draw 10 day slope of close

add column degreechg
add column angledeg2

Sort column 5 descending

stocktrader
294 posts
msg #127497
Ignore stocktrader
3/3/2016 11:18:43 PM

I'm the original developer of this code ~9 years ago and still use it today in my binary sorting filter (using TRO's Logic). This is essentially Trig math, so I would think that you can apply it to your slope idea with a little effort.

StockFetcher Forums · General Discussion · Change to determine angle of any sloping line<< >>Post Follow-up

*** Disclaimer *** StockFetcher.com does not endorse or suggest any of the securities which are returned in any of the searches or filters. They are provided purely for informational and research purposes. StockFetcher.com does not recommend particular securities. StockFetcher.com, Vestyl Software, L.L.C. and involved content providers shall not be liable for any errors or delays in the content, or for any actions taken based on the content.


Copyright 2022 - Vestyl Software L.L.C.Terms of Service | License | Questions or comments? Contact Us
EOD Data sources: DDFPlus & CSI Data Quotes delayed during active market hours. Delay times are at least 15 mins for NASDAQ, 20 mins for NYSE and Amex. Delayed intraday data provided by DDFPlus


This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.