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

RE: [EquisMetaStock Group] Need help with formula



PureBytes Links

Trading Reference Links

Gernot
I'm not sure what code this is, but for "null" I get an error message - not
recognised . pr1,pd,mt would all have to be defined as inputs and MS doesn't
like the underscore. What's your charting program? 

Andrew


-----Original Message-----
From: Dusant [mailto:dusant@xxxxxxxxxxxxxxxxxx] 
Sent: Thursday, July 01, 2004 4:53 AM
To: equismetastock@xxxxxxxxxxxxxxx
Subject: Re: [EquisMetaStock Group] Need help with formula


Gernot,
:P
First of all, let me confess that the thought of using "null" did not occur
to me. 
Second, let me try it out in MS, and then revert.
BTW, did you try out the renko formula in the Russian site, which I had
posted earlier. Seems they have already done the hard work. Dusant Chief
Architect http://www.candlestrength.com/

	----- Original Message ----- 
	From: TaoTrader <mailto:taotrader@xxxxxxxxxxx>  
	To: equismetastock@xxxxxxxxxxxxxxx 
	Sent: Thursday, July 01, 2004 10:04 AM
	Subject: Re: [EquisMetaStock Group] Need help with formula

	Dusant, 
	 
	I understand that Null may not be mentioned but I have an MS script
with a Null statement that works just fine in my charting program.  Check it
out and see if it runs.
	 
	The script is a bicolored MA.  The MA is one color (of your
choosing) if price is above it, and another if price is below it.
	 
	MA:=mov(pr1,pd,mt);
	MA_UP:=if(pr>MA,MA,null);
	MA_DOWN:=if(pr<MA,MA,null);
	MA_UP;
	MA_DOWN;
	 
	The reason there is a "pr" and a "pr1", so that you can choose
different prices for the two.
	 
	Gernot
	 

		----- Original Message ----- 
		From: Dusant <mailto:dusant@xxxxxxxxxxxxxxxxxx>  
		To: equismetastock@xxxxxxxxxxxxxxx 
		Sent: Wednesday, June 30, 2004 11:08 PM
		Subject: Re: [EquisMetaStock Group] Need help with formula

		TaoTrader,
		The MS formula builder does not allow "null".
		Check it out.
		Dusant
		Chief Architect
		http://www.candlestrength.com/

			----- Original Message ----- 
			From: TaoTrader <mailto:taotrader@xxxxxxxxxxx>  
			To: equismetastock@xxxxxxxxxxxxxxx 
			Sent: Wednesday, June 30, 2004 4:52 PM
			Subject: Re: [EquisMetaStock Group] Need help with
formula

			Dusant, how about "Null"
			 
			if condition then "action", else "no action" (Null)
			 
			Gernot

				----- Original Message ----- 
				From: Dusant
<mailto:dusant@xxxxxxxxxxxxxxxxxx>  
				To: equismetastock@xxxxxxxxxxxxxxx 
				Sent: Wednesday, June 30, 2004 5:35 AM
				Subject: Re: [EquisMetaStock Group] Need
help with formula

				TaoTrader,
				This code is not possible to execute in MS,
as the MS language does not accept the normal programming syntax "if(
condition, then)".
				It needs it like this: "if( condition, then,
else)"
				What conditions are you going to impose for
the "else"?
				Dusant
				Chief Architect
				http://www.candlestrength.com/

					----- Original Message ----- 
					From: TaoTrader
<mailto:taotrader@xxxxxxxxxxx>  
					To: equismetastock@xxxxxxxxxxxxxxx 
					Sent: Tuesday, June 29, 2004 6:27 PM
					Subject: Re: [EquisMetaStock Group]
Need help with formula

					Thanks, Dusant, for your reply.
Unfortunately, external functions won't help me.  In my broker's forex
charting program you can write your own indicator scripts using a subset of
the MS commands.  However, it isn't possible to call external functions via
DLLs.  I thought if I could just program Renko charts with the available MS
commands that that would suffice.
					 
					By the way, I've just come across
another script (see below) at a German trading site.  However, it looks like
it's generating a line chart based on Renko data instead of the chart
itself.  I ran it as is in my program but it did't work ( no line, just
blank).  If someone could run the script im MS and let me know what it
works.  The code below includes comments for each line.
					 
					Cheers,
					Gernot
					 
					K:=150; {brick size}

					RenkoLine:=if(Cum(1)=1,Close,

					{Last Renko white (up)?}

					if(PREV>=0, 

					{Last Renko is white.}

					{Reversal?}

					if(C<=PREV-2*K,

					{Reversal!}

					-(PREV-floor(Max(PREV-C,0)/K)*K),

					{New white Renkos?}

					floor(Max(C-PREV,0)/K)*K+PREV),

					{Last Renko is black (down).}

					{Reversal?}

					if(C>=abs(PREV)+2*K,

					{Reversal!}

					-PREV+floor(Max(C-abs(PREV),0)/K)*K,

					{New black Renkos?}

	
floor(Max(abs(PREV)-C,0)/K)*K+PREV)));

					RL:=abs(RenkoLine);

					RL;

					 

					----- Original Message ----- 
					From: Dusant
<mailto:dusant@xxxxxxxxxxxxxxxxxx>  
					To: equismetastock@xxxxxxxxxxxxxxx 
					Sent: Tuesday, June 29, 2004 8:06 AM
					Subject: Re: [EquisMetaStock Group]
Need help with formula

					TaoTrader,
	
http://195.131.102.216/cgi-bin/ksr?file=msx_ksr_en
					You need to download the DLL as the
codes are written with the support of the external DLL.
					You need not write any code
yourself, import the formula using their files.
					This DLL has a great utility to
write values to a text file too.
					Dusant
					Chief Architect
					http://www.candlestrength.com/
					 

					----- Original Message ----- 
					From: TaoTrader
<mailto:taotrader@xxxxxxxxxxx>  
					To: equismetastock@xxxxxxxxxxxxxxx 
					Sent: Tuesday, June 29, 2004 8:00 AM
					Subject: Re: [EquisMetaStock Group]
Need help with formula

					Hi Roy,
					 
					Thanks for the response.  Yeah, I
realized the script is not in Metastock language.  However, the odd thing is
that I found the formula at a web site on external meatstock function.  See
web attached web site:
					 
					http://www.ksr.sp.ru/msx/msxen.htm
					 
					and go down to:
					4. Renko-Adaptive indicator
"Renko_Adaptive
					 
					I understand you're busy and
wouldn't ask you to take up your time.  I posted the request in the forum
because Metastock has built-in Renko charts.  So, I thought that there must
be a way to also code them with the MS language.  Although I understand that
the built-in stuff is not likely to be written MS format.
					 
					Thanks again for your reply
					Gernot








Yahoo! Groups Sponsor	 
ADVERTISEMENT
click here
<http://us.ard.yahoo.com/SIG=1297a212k/M=295196.4901138.6071305.3001176/D=gr
oups/S=1705375617:HM/EXP=1088758377/A=2128215/R=0/SIG=10se96mf6/*http://comp
anion.yahoo.com> 	
 
<http://us.adserver.yahoo.com/l?M=295196.4901138.6071305.3001176/D=groups/S=
:HM/A=2128215/rand=362597558> 	

  _____  

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
<mailto:equismetastock-unsubscribe@xxxxxxxxxxxxxxx?subject=Unsubscribe> 
	  
*	Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service
<http://docs.yahoo.com/info/terms/> . 





------------------------ Yahoo! Groups Sponsor --------------------~--> 
Yahoo! Domains - Claim yours for only $14.70
http://us.click.yahoo.com/Z1wmxD/DREIAA/yQLSAA/BefplB/TM
--------------------------------------------------------------------~-> 

 
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/