StockFetcher Forums · Filter Exchange · CANSLIM Level Calculator - Based on the work of WIlliam O'Neil<< >>Post Follow-up
WON_Fanboy
1 posts
msg #157214
Ignore WON_Fanboy
modified
7/12/2021 9:54:11 PM

Calculator the stop loss and profit target levels of CANSLIM.
As well as the trade size based of the % risk of capital.

Variables to change:
* symlist(BILL,ZDGE) - Change to the symbols you want
* set{AccountSize, 60000} - Change the 60000 to your account size
* set{RiskPct, 0.01} - Change 0.01 to your % risk
* set{EntryLevel, Donchian Upper Band(20,0)} - Change (20,0) to suit the current base length

After the script is run, click on the charts and a window will open.
You will see the exact figure marked at the right hand side of the lines.

Here is the faithful original version with 7-8% SL and 20-25% TP.

Fetcher[// The CANSLIM Levels calculator. Based on the work of William O'Neil.

Apply to symlist(BILL,ZDGE) // Pick your ticker.
set{AccountSize, 60000} // Account size.
set{RiskPct, 0.01} // Risk Percentage.

set{EntryLevel, Donchian Upper Band(20,0)} // Entry at 20-Day High. Adjust to suit each chart.
set{StopLoss_8pct, EntryLevel*0.92} // 7% Stop
set{StopLoss_7pct, EntryLevel*0.93} // 8% Stop
set{ProfitTarget_20pct, EntryLevel*1.20} // 20% Target
set{ProfitTarget_25pct, EntryLevel*1.25} // 25% Target

Draw close line at EntryLevel
Draw close line at StopLoss_8pct
Draw close line at StopLoss_7pct
Draw close line at ProfitTarget_20pct
Draw close line at ProfitTarget_25pct

set{RiskSize, AccountSize*RiskPct}
set{X_8pct,EntryLevel-StopLoss_8pct}
set{LotSize_8pctStop,RiskSize/X_8pct}
set{X_7pct,EntryLevel-StopLoss_7pct}
set{LotSize_7pctStop,RiskSize/X_7pct}

Draw LotSize_8pctStop line at LotSize_8pctStop
Draw LotSize_8pctStop line at LotSize_7pctStop
Do not draw LotSize_8pctStop
]



Here is an simplified version with 7.5% SL and 22.5% TP.

Fetcher[// The CANSLIM Levels calculator. Based on the work of William O'Neil.

Apply to symlist(BILL,ZDGE) // Pick your ticker.
set{AccountSize, 60000} // Account size.
set{RiskPct, 0.01} // Risk Percentage.

set{EntryLevel, Donchian Upper Band(20,0)} // Entry at 20-Day High. Adjust to suit each chart.
set{StopLoss, EntryLevel*0.925} // 7.5% Stop
set{ProfitTarget, EntryLevel*1.225} // 22.5% Target

Draw close line at EntryLevel
Draw close line at ProfitTarget
Draw close line at StopLoss

set{RiskSize, AccountSize*RiskPct}
set{X,EntryLevel-StopLoss}
set{LotSize,RiskSize/X}

Draw LotSize line at LotSize
Draw LotSize line at Round(LotSize,0)
Do not draw LotSize
]



Nobody
404 posts
msg #157222
Ignore Nobody
7/13/2021 4:24:29 PM

Thank you WON_Fanboy



nibor100
1,031 posts
msg #157227
Ignore nibor100
7/14/2021 4:25:21 PM

A couple of chart related tips:

1. if you add the following sample line to his CanSlim filter you will be able to see the values for each graph data point by clicking the chart and slowly dragging it to the right, the number inside the box of the same color as the line will change for each day.

draw EntryLevel on plot price

2. If you don't want to edit the filter to change the symbol list before you look at the charts, you can just run the filter as is, bring up the chart, and type in a symbol name in the box at the top left and click on the word chart to the right of that box and the chart will change to your symbol and apply all of the filter criteria to that symbol's chart.

It occurred to me that this chart filter capability may be one of the primary reasons there are complexity limits on filters.....

Ed S.

StockFetcher Forums · Filter Exchange · CANSLIM Level Calculator - Based on the work of WIlliam O'Neil<< >>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.