Hi all,
I came up with the following but I have a problem duplicating this in an exploration for 5 different stocks. What is the best way to implement this to 5 different stocks?
thanks
tony
I came up with the following but I have a problem duplicating this in an exploration for 5 different stocks. What is the best way to implement this to 5 different stocks?
thanks
tony
TradeOpenNumber = Param("1st Trade Open Number",0.83,0,1,.01);
ProfitTargetNumber = Param("Profit Target Number",1.39,0,2,.01);
RiskNumber = Param("Risk Number",1.67,0,2,.01);
MarketHours = TimeNum()>=92900 AND TimeNum()<=160000;
TodayOpen = TimeFrameGetPrice( "O", inDaily, 0 );
TodayHigh = TimeFrameGetPrice( "H", inDaily, 0 );
TodayLow = TimeFrameGetPrice( "L", inDaily, 0 );
entry1 = todayOpen + TradeOpenNumber ;
Long = Cross ( C, entry1) ;
entry2 = todayOpen - TradeOpenNumber ;
Short = Cross ( entry2, C ) ;
Sell1 = entry1 + ProfitTargetNumber;
Cover1 = entry2 - ProfitTargetNumber;
reverse_short = TodayHigh - RiskNumber ; //round to lower 1/8
reverse_long = TodayLow + RiskNumber ; //round to higher 1/8
reverse_long = TodayLow + RiskNumber ; //round to higher 1/8
entries = Long OR Short ;
exit = IIf( Long , Sell1, IIf( Short, Cover1, 0 ));
Filter = entries ;
AddColumn (TodayOpen, "Open", 1.2) ;
AddColumn (entry1, "Long", 1.2, IIf ( long, colorBlue, 0) ) ;
AddColumn (entry2, "Short", 1.2, IIf ( Short, colorRed, 0 ) ) ;
AddColumn (IIf (Long, Sell1, IIf (Short, Cover1, 0)), "Profit Target" , 1.2) ;
AddColumn (IIf (C>entry1, reverse_short, IIf (Short, reverse_long, 0)), "Reversal", 1.2 ) ; __._,_.___
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 other support material please check also:
http://www.amibroker.com/support.html
SPONSORED LINKS
| Investment management software | Real estate investment software | Investment property software |
| Software support | Real estate investment analysis software | Investment software |
YAHOO! GROUPS LINKS
- Visit your group "amibroker" on the web.
- To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
- Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
