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

RE: [amibroker] Re: Plot Line



PureBytes Links

Trading Reference Links

You are right Herman, wrong label on my part. I used the words trend line when I should just say horizontal line but

the important part is that I want to be able to move the lines around the chart just like I can when I use the drawing tool

called “horizontal line”. Plus the “horizontal line” keeps the value of Y which I would use for the price when sending orders.

 

Also, I don’t want to have to open up the parameters to adjust location of the lines.


Does this make sense?

 

Once my trigger line is crossed then the order is sent as a bracket order.

 

 

From: amibroker@xxxxxxxxxxxxxxx [mailto:amibroker@xxxxxxxxxxxxxxx] On Behalf Of Herman
Sent: Saturday, March 15, 2008 12:53 PM
To: KBH
Cc: amibroker@xxxxxxxxxxxxxxx
Subject: Re: [amibroker] Re: Plot Line

 

These are not trend lines...

 

what you are doing is simple plotting a constant price. In its simplest form, something like:

 

LMTPrice = Param("LMTPrice",50,10,100,0.01); // or what ever range.

Short = cross(C,LMTPrice);

Plot(LMTPrice,"LMTPrice",2,1);

 

herman

 

 

For tips on developing Real-Time Auto-Trading systems visit:

http://www.amibroker.org/userkb/

 

Saturday, March 15, 2008, 6:47:25 PM, you wrote:

 

> 

Maybe I am not making myself clear, I want the visual lines so I can ….. Let me give you a picture

 

See attached.

 

So what I would have  at the top of the chart are 2 buttons LONG and SHORT when I see price action that I want to trade Long

I would click the Long button and the AFL code would create 3 trend lines with the appropriate study ID and in this case for the green 

trigger line  it would be “RE” for resistance, then using Tomasz’s “Trend Line Broken Code”  

 

buy = cross( study( "RE" ), close );

 

the other 2 lines would just be the y = values (variables) for the prices of the stop and target. 

 

A couple of more things when either the LONG or SHORT button is clicked the 3 trend lines that are created  are just placed in the middle of 

the chart with some separation between each one, then they would be dragged into the appropriate location.

 

Also note the order of lines relative to Long or Short.  Trigger line would always be in the middle with Stop line and Target line either above /below

the trigger line depending if going long or short.

 

Hopefully I made some sense with the above.

 

 

 

 

 

 

 

 

 

 

From: amibroker@xxxxxxxxxxxxxxx [mailto:amibroker@xxxxxxxxxxxxxxx] On Behalf Of hoolee0820

Sent: Saturday, March 15, 2008 10:32 AM

To: amibroker@xxxxxxxxxxxxxxx

Subject: [amibroker] Re: Plot Line

 

I got it now, just didn't have the word 'automation' in my mine at

first, given your current programing experience.

 

I've long given up the dream of fully automating my systems. That

doesn't mean others can't do it either. TJ and a few others like

herman and Graham are the right persons to ask.

 

Line is just a visual tool, maybe you can bypass it and just 

calculate the price levels.

 

good luck.

 

--- In amibroker@xxxxxxxxxxxxxxx, "KBH" <hawkinsk001@xxx> wrote:

> 

> Take a look at the email I just sent subject: "Question for Tomasz?"

> From: amibroker@xxxxxxxxxxxxxxx [mailto:amibroker@xxxxxxxxxxxxxxx

On Behalf

> Of hoolee0820

> Sent: Saturday, March 15, 2008 9:19 AM

> To: amibroker@xxxxxxxxxxxxxxx

> Subject: [amibroker] Re: Plot Line

> Still don't know why you have to do that in code. Can't you set the 

> ID for the line that drawn from toolbar? seems ur reinventing the 

> wheels here...

> --- In HYPERLINK

> "mailto:amibroker%40yahoogroups.com"amibroker@xxxxxxxxxxxxxxx, "KBH"

> <hawkinsk001@> wrote:

> >

> > Thanks wavemechanic, that gives me exactly what I asked for. 

> Unfortunately I

> > asked for the wrong thing.

> > 

> > What I want to create is a trend line using AFL code that has all 

> of the

> > same properties as a horizontal trend line drawn

> > 

> > with the drawing toolbar. 

> > 

> > 

> > 

> > Once initially placed on chart I would like to be able to drag it 

> up and

> > down, set its study ID, etc…. 

> > 

> > Does anybody know how to do that?

> > 

> > 

> > 

> > 

> > 

> > 

> > 

> > From: HYPERLINK

> "mailto:amibroker%40yahoogroups.com"amibroker@xxxxxxxxxxxxxxx

> [mailto:HYPERLINK

> "mailto:amibroker%40yahoogroups.com"amibroker@xxxxxxxxxxxxxxx

> On Behalf

> > Of wavemechanic

> > Sent: Saturday, March 15, 2008 7:25 AM

> > To: HYPERLINK

> "mailto:amibroker%40yahoogroups.com"amibroker@xxxxxxxxxxxxxxx

> > Subject: Re: [amibroker] Re: Plot Line

> > 

> > 

> > 

> > plot(param("line level", 25, 5, 50, 1), "", colorwhite);

> > 

> > ----- Original Message ----- 

> > 

> > From: HYPERLINK "mailto:hawkinsk001@"KBH 

> > 

> > To: 

> HYPERLINK "mailto:HYPERLINK

> "mailto:amibroker%

40yahoogroups.com"amibroker@xxxxxxxxxxxxxxx"HYPERLINK

> "mailto:amibroker%40yahoogroups.com"amibroker@xxxxxxxxxxxxxxx 

> > 

> > Sent: Saturday, March 15, 2008 2:14 AM

> > 

> > Subject: RE: [amibroker] Re: Plot Line

> > 

> > 

> > 

> > I want to create the horizontal trend line thru AFL code not by 

> using the

> > toolbar.

> > 

> > 

> > 

> > thanks

> > 

> > turn off "snap to price" and then add a "horizontal line" from 

> > toolbar, you should be able to drag the line around in your chart.

> > 

> > I am trying to plot a horizontal trend line in the center of a 

> > price chart thru AFL code and after it is plotted on price chart 

> can 

> > select it and move it around the chart. I realize I can uses the 

> > horizontal trend line drawing tool to create the above but I want 

to

> > be able to create it using code. 

> > 

> > Also I would like to be able to control the length and position. 

> > Here is what I got so far but it won't 

> > do what I want it to do. All it does is put a horizontal line 

> > across my chart which I can't move. I understand why it can't 

move, 

> > 

> > 

> > 

> > because of the "665" but I don't know what to do about it. Don't 

> > laugh it took me and 1 ½ hours to create it.

> > 

> > Plot(665, "Line", colorRed, styleLine,0, 0, 0);

> > 

> > Thanks,

> > Bruce

> > > 

> > > 

> > > No virus found in this outgoing message.

> > > Checked by AVG. 

> > > Version: 7.5.519 / Virus Database: 269.21.7/1329 - Release 

Date: 

> > 3/14/2008

> > > 12:33 PM

> > >

> > 

> > 

> > 

> > No virus found in this incoming message.

> > Checked by AVG.

> > Version: 7.5.519 / Virus Database: 269.21.7/1329 - Release Date: 

> 3/14/2008

> > 12:33 PM

> > 

> > 

> > 

> > No virus found in this outgoing message.

> > Checked by AVG.

> > Version: 7.5.519 / Virus Database: 269.21.7/1329 - Release Date: 

> 3/14/2008

> > 12:33 PM

> > 

> > _____ 

> > 

> > No virus found in this incoming message.

> > Checked by AVG Free Edition. 

> > Version: 7.5.516 / Virus Database: 269.21.7/1319 - Release Date: 

> 3/8/2008

> > 10:14 AM

> > 

> > 

> > 

> > 

> > 

> > No virus found in this incoming message.

> > Checked by AVG.

> > Version: 7.5.519 / Virus Database: 269.21.7/1329 - Release Date: 

> 3/14/2008

> > 12:33 PM

> > 

> > 

> > No virus found in this outgoing message.

> > Checked by AVG. 

> > Version: 7.5.519 / Virus Database: 269.21.7/1329 - Release Date: 

> 3/14/2008

> > 12:33 PM

> >

> No virus found in this incoming message.

> Checked by AVG.

> Version: 7.5.519 / Virus Database: 269.21.7/1330 - Release Date: 

3/15/2008

> 2:36 PM

> No virus found in this outgoing message.

> Checked by AVG. 

> Version: 7.5.519 / Virus Database: 269.21.7/1330 - Release Date: 

3/15/2008

> 2:36 PM

> 

 

No virus found in this incoming message.

Checked by AVG.

Version: 7.5.519 / Virus Database: 269.21.7/1330 - Release Date: 3/15/2008 2:36 PM

 

 

 

No virus found in this outgoing message.

Checked by AVG.

Version: 7.5.519 / Virus Database: 269.21.7/1330 - Release Date: 3/15/2008 2:36 PM

 

No virus found in this incoming message.
Checked by AVG.
Version: 7.5.519 / Virus Database: 269.21.7/1330 - Release Date: 3/15/2008 2:36 PM

__._,_.___

Please note that this group is for discussion between users only.

To get support from AmiBroker please send an e-mail directly to
SUPPORT {at} amibroker.com

For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/

For other support material please check also:
http://www.amibroker.com/support.html




Your email settings: Individual Email|Traditional
Change settings via the Web (Yahoo! ID required)
Change settings via email: Switch delivery to Daily Digest | Switch to Fully Featured
Visit Your Group | Yahoo! Groups Terms of Use | Unsubscribe

__,_._,___

No virus found in this outgoing message.
Checked by AVG.
Version: 7.5.519 / Virus Database: 269.21.7/1330 - Release Date: 3/15/2008 2:36 PM