PureBytes Links
Trading Reference Links
|
Thanks for the feedback - and glad all is hunkey dorey now!
Regards
MG Ferreira
TsaTsa EOD Programmer and trading model builder
http://www.ferra4models.com
http://fun.ferra4models.com
--- In equismetastock@xxxxxxxxxxxxxxx, loudhoward2 <no_reply@xxxx> wrote:
> ...don't worry about it MG. I've finally worked it out.
>
> N:=N and Alert(N=0,2) reduces the instances of my buy siganl to the
> first one only.
>
> (C>C1 AND Ref(C,-1)<=C1 AND BarsSince(N)<=2)*C
>
> This part of the code identifys the first close above the the 'N'
> signal, occuring 2 days directly after 'N'
>
> Got there in the end, finally.
>
> Lou
>
> --- In equismetastock@xxxxxxxxxxxxxxx, loudhoward2 <no_reply@xxxx>
> wrote:
> > Hi MG,
> > Thanks for taking the time to read thru my code and explaining
> > in "English" what it all means.
> >
> > What I was originally getting from my code was multiple buy
> signals
> > one day after another (up until the N:=N part). The rest of the
> code
> > after that was trying to isolate the "first" buy signal, hold that
> > in memory, then gve a "true buy" signal after a close higher than
> > the original "first" buy signal.
> >
> > It's giving me the signal as I would expect. I understand 99% of
> the
> > code apart from {BarsSince(N)<=5*C} but somehow it produces what I
> > want..... and I'm not comfortable with that.
> >
> > **any more ideas?
> >
> > I've only just recently subscribed to Roy's newsletter (so far
> > playing catchup, some things a sinking in!) but have just read
> about
> > whether a trend is in progress and how strong that trend would
> > likely be, eventually I'd like to incorporate those indicators in
> my
> > expert/tester aswell.
> >
> > Thanks,
> > Lou
> >
> >
> > --- In equismetastock@xxxxxxxxxxxxxxx, mgf_za_1999 <no_reply@xxxx>
> > wrote:
> > > I'll have a go, see below
> > >
> > > Regards
> > > MG Ferreira
> > > TsaTsa EOD Programmer and trading model builder
> > > http://www.ferra4models.com
> > > http://fun.ferra4models.com
> > >
> > >
> > > --- In equismetastock@xxxxxxxxxxxxxxx, loudhoward2
> <no_reply@xxxx>
> > wrote:
> > > > Hi all,
> > > >
> > > >
> > > >
> > > > I'm trying to figure out some code I have but can't quite
> > > > understand
> > > > one section. Can anyone explain in "English" what it is
> > > > I'm trying
> > > > to achieve? (I know that sounds weird, but I had a friend help
> > me
> > > > out with some code and I've forgotten exactly what it's meant
> > > > to do
> > > > plus I should be using code I'm not 100% confident about)
> > > >
> > > >
> > > >
> > > > System is based on a triple moving average
> > > > N is the signal variable ie buy
> > > >
> > > >
> > > >
> > > >
> > > > SMA:=Mov(C,20,E);
> > > >
> > > > MMA:=Mov(C,60,E);
> > > >
> > > > LMA:=Mov(C,120,E);
> > > >
> > > >
> > > >
> > > > N:=C>SMA AND C>MMA AND C>LMA
> > > >
> > >
> > > if the latest close is above all three moving averages
> > >
> > > > AND
> > >
> > > and ...
> > >
> > >
> > > >
> > > > {No Cross() function used for MA cross overs, not sure if this
> > the
> > > > best alternative, heard the Cross() functions has its
> > limitations}
> > > >
> > > > SMA>MMA AND MMA>LMA
> > >
> > > the short is above the medium and the medium above the slow
> moving
> > > average (translate - trend is very strong, question - will it be
> > > sustainable)
> > >
> > > >
> > > > AND
> > >
> > > and ...
> > >
> > > >
> > > > {ROC() used to highlight that a MA is rising}
> > > >
> > > > ROC(SMA,8,%)>0 AND ROC(MMA,10,%)>0 AND ROC(LMA,6,%)>0
> > >
> > >
> > > short moving average is higher than 8 days ago, medium is higher
> > than
> > > ten and slow is higher than 6 days ago
> > >
> > >
> > >
> > > >
> > > > AND
> > >
> > > and ....
> > >
> > >
> > > >
> > > > {Alert used to pickup pull backs in momentum}
> > > >
> > > > Alert(RSI(C,7)<=38,20);
> > >
> > >
> > > 7 day RSI has been less than 38 during any of the previous 20
> days
> > >
> > > >
> > > >
> > > >
> > > > N:=N
> > >
> > >
> > > Huh? Is this really needed? Why not continue the formula, or am
> I
> > > missing something.....
> > >
> > >
> > > >
> > > > AND
> > > >
> > > > Alert(N=1,2); {lets me know when I have a binary 1 (buy
> signal)
> > in
> > > > the last 2 days}
> > > >
> > > > {C1 gives me the closing price when my first signal (N) was
> > achieved}
> > > >
> > > > C1:=ValueWhen(1,N,C);
> > > >
> > > > {Today's close must be > the signal close price}
> > > >
> > > > C>C1 AND Ref(C,-1)<=C1
> > > >
> > > > AND
> > > >
> > > > {NOT SURE ABOUT THIS LAST LINE?? Is it to do with being in the
> > trade
> > > > for at least 5 days? Why multiply by the Close?}
> > > >
> > > > BarsSince(N)<=5*C
> > > >
> > > >
> > >
> > > Huh? Doesn't make a lot of sense. If you use the close in the
> > > formula in this way, then it will only work for some tickers.
> > >
> > >
> > > >
> > > >
> > > >
> > > > Regards,
> > > >
> > > > Lou
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/equismetastock/
<*> To unsubscribe from this group, send an email to:
equismetastock-unsubscribe@xxxxxxxxxxxxxxx
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
|