StockFetcher Forums · View by Author: (181 messages)  [ Display By: Date / Subject ]<< 1 2 3 4 5 ... 19 >> 
Filter Exchange · Trend Trader Strategy
push5280
msg #158446
modified
1/23/2022 6:51:37 PM

I think I have the IF, ELSEIF,ELSE part figured out but I'm at what I think is the last line and it breaks.

I think my logic is correct in the IF, ELSEIF, ELSE parts but I need some help from SF coders who are better than me.
Any help is appreciated!



/*1)avrTR = weightedaverage[Length](AverageTrueRange[1](close))
2)highestC = highest[Length](high)
3)lowestC = lowest[Length](low)
4)hiLimit = highestC[1]-(avrTR[1]*Multiplier)
5)lolimit = lowestC[1]+(avrTR[1]*Multiplier)
6)if(close > hiLimit AND close > loLimit) THEN
7) ret = hiLimit
8)ELSIF (close < loLimit AND close < hiLimit) THEN
9) ret = loLimit
10)ELSE
11) ret = ret[1]
12)ENDIF
13)RETURN ret coloured(238,238,0) as "Trend Trader"*/
Fetcher[
/*avrTR = weightedaverage[Length](AverageTrueRange[1](close))*/
set{avrTR_multiplier, Weighted ATR(21) 1 day ago * 3}
draw avrTR_multiplier
/* highestC = highest[Length](high) */
set{highestC, close 21 day high}
draw highestC
/* lowestC = lowest[Length](low) */
set{lowestC, close 21 day low}
draw lowestC
/* hiLimit = highestC[1]-(avrTR[1]*Multiplier)*/
set{hiLimit, close 21 day high 1 day ago - avrTR_multiplier}
draw hiLimit
/*lolimit = lowestC[1]+(avrTR[1]*Multiplier) */
set{loLimit, close 21 day low 1 day ago + avrTR_multiplier}
draw loLimit
/* if(close > hiLimit AND close > loLimit) */
/* we need to find if this condition is satisfied */
set{if_1, count(close > hiLimit, 1)}
set{if_2, count(close > loLimit, 1)}
set{if_3, if_1 + if_2}
set{if_3_count, count(if_3 > 1, 1)}
draw if_3_count
/*ELSIF (close < loLimit AND close < hiLimit) */
/* we need to find if this condition is satisfied */
set{elseif_1, count(close < loLimit, 1)}
set{elseif_2, count(close < hiLimit, 1)}
set{elseif_3, elseif_1 + elseif_2}
set{elseif_3_count, count(elseif_3 > 1,1)}
draw elseif_3_count
/*ELSE */
/* we need to find if this condition is satisfied */
set{else_1, if_3_count + elseif_3_count}
set{else_1_count, count(else_1 < 1, 1)}
draw else_1_count

/* set the values for TrendTrader Indicator calculations */
set{hiLimit_val, hiLimit * if_3_count}
set{loLimit_val, loLimit * elseif_3_count}
draw hiLimit_val
draw loLimit_val
set{lolimit_1, loLimit_val 1 day ago}
draw lolimit_1 on plot loLimit
/*set{hilimit_1, hiLimit_val 1 day ago}
draw hilimit_1 on plot hiLimit */
set{HandL_val, hilimit_1 + lolimit_1 }
add column HandL_val
draw HandL_val
set{handl_1, HandL_val 1 day ago}
draw handl_1
set{return_val, else_1_count * handl_1}
draw return_val


close > 1
]

Filter Exchange · Help with filter **breaking at last line**
push5280
msg #158445
modified
1/23/2022 6:15:11 PM

I moved my question to the Trend Trader thread


General Discussion · Jesse Stine
push5280
msg #158428
1/21/2022 2:11:26 PM

miketranz,

look for a free pdf download online and then cancel your book purchase.


General Discussion · Most Volatile Swinging Stocks
push5280
msg #158409
1/17/2022 12:32:27 PM

** ... just calculate by the percentage difference between the 6-month high and 6-month low. Then sort in descending order. ***

***********************************************

X, that is the method I use also except I use the 252 day high and low. Also filter by >= 3.

General Discussion · can some one help me with this ?
push5280
msg #158366
1/7/2022 9:36:17 PM

up 4%+ from prior day close
volumes is greater than yesterday volume
volume is greater than 100000
thank you guys, thank you. you helped me so much!

****************************************************

Fetcher[
set{close_4pct, close 1 day ago * 1.04}

close >= close_4pct
volume > volume 1 day ago
volume > 100,000
]



General Discussion · Watcha been humming lately? Share ure favorite tunes...
push5280
msg #158003
11/6/2021 7:37:18 PM

This is a cover band from the Atlanta area called Foxes and Fossils, this is a video from their first performance in 2010 at a place called Bella's Pizza Bar and Grill. The girls were about 15 years old at the time so it's obvious that they were nervous at the onset but they relaxed and were quite comfortable by the midpoint. If you Google them I think Graham Nash congratulated them on the cover.
https://www.youtube.com/watch?v=S23VK1v9dB8

General Discussion · MACD-H % filter
push5280
msg #157998
11/5/2021 7:13:03 PM

/* Hi all,
I was wondering if it possible to create a filter based on the MACD-H %.
For example: today the MACD-H is 50% less than the value the MACD-H was 20 days ago. */

Fetcher[
set{macdH_20, macd histogram(12,26,9) 20 days ago}
set{macdH_50pct, macdH_20 * .5}
set{my_macd, macd histogram(12,26,9)}
market is not otcbb
average volume(30) 100,000
close > 1
my_macd <= macdH_50pct
PlotType{my_macd,zerobar}
do not draw macdH_50pct
]



General Discussion · need help on filter
push5280
msg #157850
10/11/2021 9:49:31 PM


hyblair232231
10/11/2021 3:31:37 PM

how does a filter describe a double top formation with in 30 days of each other?
*****************************************************************************************************

start here
https://www.stockfetcher.com/sfforums/?q=view&fid=1002&tid=33476&qrid=&isiframe

General Discussion · trading day vs calendar day
push5280
msg #157696
9/28/2021 11:50:51 AM

Trading days

General Discussion · Draw position entry price on chart
push5280
msg #157512
modified
9/7/2021 11:21:48 PM

.

StockFetcher Forums ·  · << 1 2 3 4 5 ... 19 >>

*** 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 2021 - 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.