PureBytes Links
Trading Reference Links
|
Jaime,
Ron is correct.
Your formula sets the a variable as 0 every bar.
It is possible to translate other programs such as wealth-lab to
metastock...I have done it. Show us the code and we'll see what we
can do.
Preston
--- In equismetastock@xxxxxxxxxxxxxxx, "jaime" <xtal32768@xxx> wrote:
>
> Hi Ron,
>
> Thank you for the reply.
> Take notice that i'm adding 1 to the previous value of a (in
theory).
> So, if in one bar the variable a is equal to 0, in the following
bar
> it will add 1 and a equals 1. After another bar, i will add 1 more
> and a should be equal to 2, and so on. That's the theory as far as
i
> can understand MS.
> In practice thing don't happen that way. It seems that MS Will not
> consider the value of the variable that is plotted when the
function
> Ref() is used, it considers always the constant 0. I don't know
why,
> it doesn't make sense to me and it limits even more the MS Script.
>
> I cannot use the function Cum() because my goal is not producing
an
> incrementing line. I just simplified my script so that i could
> explain the issue to you. My goal is to translate a small program
> from wealth-Lab Developer to MS. Unfortunately i think it won't be
> possible.
>
> Regards,
> Jaime
>
>
>
>
> --- In equismetastock@xxxxxxxxxxxxxxx, "Ron Berlin" <rsb_44@>
> wrote:
> >
> > Jaime-
> >
> >
> > Your code sets a to the constant 0 (zero). You then add 1 to it
to
> get the
> > constant 1. That's what you are plotting. Try setting a to 3.
> You'll get a
> > plot of 4.
> >
> > You're looking for
> > CUM(1);
> > Which is a bar counter increasing from left to right.
> >
> > Ron
> >
> >
> > >From: "jaime" <xtal32768@>
> > >Reply-To: equismetastock@xxxxxxxxxxxxxxx
> > >To: equismetastock@xxxxxxxxxxxxxxx
> > >Subject: [EquisMetaStock Group] Indicator Help
> > >Date: Tue, 24 Apr 2007 21:37:11 -0000
> > >
> > >Hi,
> > >
> > >I'm trying something with Metastock and its behavior is not
what i
> > >expected. When i create an indicator with the following code:
> > >
> > >a:= 0;
> > >a:= Ref(a,-1) + 1;
> > >a;
> > >
> > >MS plots a straight line with the value 1. I was expecting a
line
> > >increasing by +1 in each bar. Anyone knows why this happens?
> > >I'm using MS Pro 8.0.
> > >
> > >Thank you,
> > >Jaime
> > >
> > >
> > >
> >
>
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/equismetastock/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/equismetastock/join
(Yahoo! ID required)
<*> To change settings via email:
mailto:equismetastock-digest@xxxxxxxxxxxxxxx
mailto:equismetastock-fullfeatured@xxxxxxxxxxxxxxx
<*> 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/
|