[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: calculations



PureBytes Links

Trading Reference Links

Ton,

I forgot to mention, but as you surmised, I reference these other variables
using calls and never, ever reference COMHX0109 directly.  COMHX01X09 is
just a convenient way to group 9 similar variables.

With regards to eliminating the extra ";", I tried your suggestion when
checking out each of these variables.  Whenever I left it out, I got an
error message, primarily because there were other variables following it.

The way I look at these variables is that they are "called" procedures that
I use to perform my calculations.  I'm still a programmer, basically, and am
trying to get MS to duplicate what we have running in other languages in
order to take advantage of its System Tester capabilities.

Regards,

Guy

" If at first you don't succeed, skydiving is not for you."

-----Original Message-----
From: owner-metastock@xxxxxxxxxxxxx [mailto:owner-metastock@xxxxxxxxxxxxx]On
Behalf Of A.J. Maas
Sent: Sunday, October 01, 2000 9:09 AM
To: Metastock-List
Subject: Re: calculations

> The only thing missing is COMHX01 and COMHX02.  When running, it works
> sporadically or not at all.  I cut and pasted COMHX01 and COMHX02 into
their
> own indicators (which is how I tested them in the first place) and they
work
> fine.

Seems that there is a lot missing, for it to work ok.

The Vars
No doubt transponing the Vars 1 and 2 into separate indicators will work,
since
that the orginal Vars 3 to 9 printed below do not contain any errors.

Thus no doubt that the Vars 1 to 9 are correct. However now for the
Indicator............

The Indicator
The expression that makes up the Indicator, is only calling the Var 9.
As such, will also be the only Var that makes up the Indicator-base for the
calculation
formula of the COMHX01X09 Indicator.

And thus will be the only Var that is set out to do the Indicator's
calculation work.
This expression will thus be the only Var in the Indicator that is
calculated, and not the
any of the other 8 Vars, since that Var 9 is the only VAR that's being
adressed {called},
and that therefore makes up the COMHX01X09 Indicator.

Remains that the other 8 Vars are thus useless {superflouis} put here and
are thus
unnessecary added lines in the Indicator. They are NOT part of NOR do they
make
up the COMHX01X09 indicator.

Thus unless you include them each by their own indicator-reference calls,
then in your
instance, the Var 9 "is also" the COMHX01X09 indicator.

And like mentioned before in a prev mail, the " ; " separator is also put
here only distracting
the program, eg since that another reference call {expression} is expected
{but not present}.

Regards,
Ton Maas
ms-irb@xxxxxxxxxxxxxxxx
Dismiss the ".nospam" bit (including the dot) when replying.
Homepage  http://home.planet.nl/~anthmaas


----- Oorspronkelijk bericht -----
Van: "Guy Tann" <grt@xxxxxxxxxxxx>
Aan: "Metastock User Group" <metastock-list@xxxxxxxxxxxxx>
Verzonden: zondag 1 oktober 2000 8:41
Onderwerp: calculations


> Don,
>
> Here's part of what I had in one indicator that I called COMHX01X09.
>
> COMHX03:= ( FmlVar("COMH-MXX","COMHMXX") - Ref(
> FmlVar("COMH-MXX","COMHMXX") , -3 )) / 3;
>
> COMHX04:= ( FmlVar("COMH-MXX","COMHMXX") - Ref(
> FmlVar("COMH-MXX","COMHMXX") , -4 )) / 4;
>
> COMHX05:= ( FmlVar("COMH-MXX","COMHMXX") - Ref(
> FmlVar("COMH-MXX","COMHMXX") , -5 )) / 5;
>
> COMHX06:= ( FmlVar("COMH-MXX","COMHMXX") - Ref(
> FmlVar("COMH-MXX","COMHMXX") , -6 ) ) / 6;
>
> COMHX07:= ( FmlVar("COMH-MXX","COMHMXX") - Ref(
> FmlVar("COMH-MXX","COMHMXX") , -7 ) ) / 7;
>
> COMHX08:= ( FmlVar("COMH-MXX","COMHMXX") - Ref(
> FmlVar("COMH-MXX","COMHMXX") , -8 ) ) / 8;
>
> COMHX09:= ( FmlVar("COMH-MXX","COMHMXX") - Ref(
> FmlVar("COMH-MXX","COMHMXX") , -9 ) ) / 9;
> COMHX09;
>
> The only thing missing is COMHX01 and COMHX02.  When running, it works
> sporadically or not at all.  I cut and pasted COMHX01 and COMHX02 into
their
> own indicators (which is how I tested them in the first place) and they
work
> fine.  I'm now moving all of these back into individual indicators.  I
have
> no idea why this didn't work since I only had 9 variables.  The COMX09;
> entry was strictly for plotting purposes so I could check out the detailed
> results (remember, I'm doing a conversion here and need to verify
> calculations to 4 decimal places).
>
> After verifying my calculation results, I delete the final COMHX09
plotting
> entry.  Anyway, why they don't work when contained in one indicator and do
> work when cut and pasted into their own indicator, I have absolutely no
> idea.
>
> Regards,
>
> Guy
>
> " If at first you don't succeed, skydiving is not for you."
>
>
>