Traderji.com - Discussion forum for Stocks Commodities & Forex

Discuss, backtest & implement pivot based trading systems here

Discuss Discuss, backtest & implement pivot based trading systems here at the Technical Analysis within the Traderji.com - Discussion forum for Stocks Commodities & Forex; hey! good work. Will use it to back test this week and let u know ...


Go Back   Traderji.com - Discussion forum for Stocks Commodities & Forex > METHODS & STRATEGIES > Technical Analysis

Notices

Technical Analysis Discussion of all the principles involved in technical analysis.


Advertise Here

Reply
 
Thread Tools
Sponsored Links
  #11  
Old 30th July 2008, 09:56 PM
Member
 
Join Date: Dec 2007
Location: 3rd ROCK from the SUN
Posts: 373
Blog Entries: 1
Thanks: 506
Thanked 486 Times in 159 Posts
man4urheart is a glorious beacon of lightman4urheart is a glorious beacon of lightman4urheart is a glorious beacon of lightman4urheart is a glorious beacon of lightman4urheart is a glorious beacon of light
Reputation: 496
Default Re: Discuss, backtest & implement pivot based trading systems here

hey! good work. Will use it to back test this week and let u know how we can improve!
Reply With Quote
Sponsored Links
  #12  
Old 30th July 2008, 10:10 PM
Member
 
Join Date: Jul 2005
Posts: 451
Thanks: 39
Thanked 56 Times in 32 Posts
kenneth will become famous soon enough
Reputation: 86
Default Re: Discuss, backtest & implement pivot based trading systems here

Hi Abhay,

As Trader No111 suggested we will repair the speedometer first. Here is AFL I suggest.
_SECTION_BEGIN("Simple Pivot based Trading System");
_SECTION_BEGIN("Price");
SetChartBkGradientFill( ParamColor("BgTop", colorLavender),ParamColor("BgBottom", colorBlack));
SetChartOptions(0,chartShowArrows|chartShowDates);
_N(Title = StrFormat("{{NAME}} - {{INTERVAL}} {{DATE}} Open %g, Hi %g, Lo %g, Close %g (%.1f%%) {{VALUES}}", O, H, L, C, SelectedValue( ROC( C, 1 ) ) ));
Plot( C, "Close", ParamColor("Color", colorBlack ), styleNoTitle | ParamStyle("Style") | GetPriceStyle() );
_SECTION_END();


UpPivot= ValueWhen(
(Ref(H,-2) > Ref(H, -4)) AND
(Ref(H,-2) > Ref(H, -3)) AND
(Ref(H,-2) > Ref(H, -1)) AND
(Ref(H,-2) > H), Ref(H,-2));

DownPivot= ValueWhen(
(Ref(L,-2) <= Ref(L, -4)) AND
(Ref(L,-2) <= Ref(L, -3)) AND
(Ref(L,-2) <= Ref(L, -1)) AND
(Ref(L,-2) <= L), Ref(L,-2));



Plot(Ref(UpPivot,2), "UpPivot", ParamColor("UpPivot Color",colorRed), ParamStyle("UpPivot Style", styleDashed));
Plot(Ref(DownPivot,2), "DownPivot",ParamColor("DownPivot Color",colorBlue), ParamStyle("DownPivot Style", styleDashed));
Regards
ken
Reply With Quote
The Following 3 Users Say Thank You to kenneth For This Useful Post:
aad (1st August 2008), indian06 (30th July 2008), SMART_Trader (30th July 2008)
  #13  
Old 30th July 2008, 10:30 PM
Member
 
Join Date: Sep 2007
Posts: 12
Thanks: 11
Thanked 0 Times in 0 Posts
indian06 is on a distinguished road
Reputation: 20
Default Re: Discuss, backtest & implement pivot based trading systems here

thanks Ken, this one is working perfectly on my charts
Reply With Quote
  #14  
Old 30th July 2008, 10:32 PM
Member
 
Join Date: Jul 2005
Posts: 451
Thanks: 39
Thanked 56 Times in 32 Posts
kenneth will become famous soon enough
Reputation: 86
Default Re: Discuss, backtest & implement pivot based trading systems here

Hi Abhay,

I have added the AFL to yours. Please see the chart.

Regards
Ken

Last edited by kenneth; 15th August 2008 at 02:46 PM.
Reply With Quote
  #15  
Old 30th July 2008, 10:43 PM
Member
 
Join Date: Jul 2005
Posts: 451
Thanks: 39
Thanked 56 Times in 32 Posts
kenneth will become famous soon enough
Reputation: 86
Default Re: Discuss, backtest & implement pivot based trading systems here

Hi Abhay

Can you also add an exploration with the following details please.

Code:
Ticker	Date/Time	      Trade	Close	ENTRY	P/L	EXIT	Risk	Sell L2 SL	P/L	BUY H2 SL	
LITL.NS	7/30/2008 3:30:00 PM	Long	324.15	321.55	2.60	318.50	-3.05	320.05	-1.50	326.50
Regards
Ken
Reply With Quote
  #16  
Old 30th July 2008, 11:00 PM
Member
 
Join Date: Sep 2007
Posts: 12
Thanks: 11
Thanked 0 Times in 0 Posts
indian06 is on a distinguished road
Reputation: 20
Default Re: Discuss, backtest & implement pivot based trading systems here

Quote:
Originally Posted by kenneth View Post
Hi Abhay,

I have added the AFL to yours. Please see the chart.

Regards
Ken
can you please post this combination of both the AFLs
Reply With Quote
  #17  
Old 31st July 2008, 12:28 PM
aad aad is offline
Member
 
Join Date: Jul 2006
Posts: 244
Thanks: 6
Thanked 23 Times in 7 Posts
aad is on a distinguished road
Reputation: 46
Default Re: Discuss, backtest & implement pivot based trading systems here

Sorry everyone as I am unable to post earlier due to some urgent priorities. But I have read the posts and feel happy that we are going in the right direction. Will definitely post tonight / tomorrow as I will be again on move for next 2-3 days including weekend after tomorrow.

Best regards,

Abhay
Reply With Quote
  #18  
Old 31st July 2008, 09:02 PM
Member
 
Join Date: Jul 2005
Posts: 451
Thanks: 39
Thanked 56 Times in 32 Posts
kenneth will become famous soon enough
Reputation: 86
Default Re: Discuss, backtest & implement pivot based trading systems here

Quote:
Originally Posted by indian06 View Post
can you please post this combination of both the AFLs
Hello Indian

Please drag and drop the AFL in to Abhay's AFL.

Regards
ken
Reply With Quote
The Following User Says Thank You to kenneth For This Useful Post:
indian06 (3rd August 2008)
  #19  
Old 31st July 2008, 10:33 PM
Member
 
Join Date: Jan 2008
Posts: 296
Thanks: 556
Thanked 554 Times in 196 Posts
citrus is a name known to allcitrus is a name known to allcitrus is a name known to allcitrus is a name known to allcitrus is a name known to allcitrus is a name known to all
Reputation: 564
Default Re: Discuss, backtest & implement pivot based trading systems here

Quote:
Originally Posted by kenneth View Post
Hello Indian

Please drag and drop the AFL in to Abhay's AFL.

Regards
ken
Dear Kenneth and Abhay
Drag and drop didn't work. Please combine both the AFLs.
Regards.
Reply With Quote
  #20  
Old 1st August 2008, 04:16 AM
aad aad is offline
Member
 
Join Date: Jul 2006
Posts: 244
Thanks: 6
Thanked 23 Times in 7 Posts
aad is on a distinguished road
Reputation: 46
Default Re: Discuss, backtest & implement pivot based trading systems here

Dear all,

Thanks everyone for your posts.

I have attached new system based on suggestions given by trader111 and code posted by Kenneth. Now our system does not work on zig() anymore.

///////////////////////////////////////////////////////////
///// Major changes done from previous version 1.0 : //////

// The method of pivot definition is changed.
// Now it does not use zig() or related functions anywhere.
// We now use method suggested by Kenneth for Pivot definition.

// Stoploss line error, that it moves in both directions after a position is taken,
// is removed. Now stoploss lines are unidirectional.

// To protect profit on long positions, SELL is triggered either when trailing buy stop
// is hit OR when previous lower pivot is cracked. Fresh long position will be initiated
// if uptrend continues after previous high pivot is cracked.

///////////////////////////////////////////////////////////

Code and back-test results, backtester settings snapshot are attached.

Backtester settings : All backtests are done using
capital - 100000/-,
max. loss per trade as % of capital – 1%
room for stoploss as % of close below pivot – 1%

Imp. regarding backtesting : Although our system indicates permissible quantity to buy / short, backtester ignores this and buys / shorts max. quantity using available funds. Hence although we are ensuring max. loss per trade is not more than 1%, backtester shows more loss than expected. Once this system is finetuned, I will write custom backtester to incorporate our settings.

Comments and suggestions, as usual, are most welcome.

Best regards,

Abhay
Attached Files
File Type: zip ver_1.1_pivot_based_trading_system.zip (46.0 KB, 46 views)
Reply With Quote
The Following User Says Thank You to aad For This Useful Post:
sikandar (1st August 2008)
Sponsored Links

Reply

Bookmarks

Tags
continuous trading system, intraday trading system, pivot based entry-exit, techincal analysis


Advertise Here


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


All times are GMT +5.5. The time now is 06:16 PM.

Indemnity, Disclaimer & Disclosure Notice:
• By visiting Traderji.com you indicate your acceptance of our Forum Rules Disclaimer & Disclosure and indemnify Traderji.com, its associates and related parties of all claims howsoever resulting from the usage of the forum.
Disclaimer: Trading or investing in stocks & commodities is a high risk activity. Any action you choose to take in the markets is totally your own responsibility. Traderji.com will not be liable for any, direct or indirect, consequential or incidental damages or loss arising out of the use of this information.
Disclosure: The information in this forum is neither an offer to sell nor solicitation to buy any of the securities mentioned herein. The writers may or may not be trading in the securities mentioned.
• All names or products mentioned are trademarks or registered trademarks of their respective owners.
General Content Disclaimer Notice:
In light of our policy of encouraging candid, open exchanges of views and the rapid distribution of information originating from many sources, Traderji.com cannot determine the accuracy of information that may be uploaded to the forum. Opinions, advice and all other information expressed by participants in discussions are those of the author. You rely on such information at your own risk. You are urged to seek professional advice for specific, individual situations and not rely solely on advice or opinions given in the discussions. Since Traderji.com is an open and free discussion forum, any comments made by members of this forum in their posts reflect their own views and not of the owner or administrator of Traderji.com. Thus the owner/administrator indemnify themselves of all claims whatsoever and will not be liable or responsible for any members comments/views in this forum Traderji.com. If you find any objectionable or offensive posts made by members of this forum which you would like to bring to our notice for removal then please Contact Us.
 


Copyright © 2001 - 2009, Traderji.com All Rights Reserved.

Recommended Websites - www.TradersEdgeIndia.com - www.TradingPicks.com - www.MasterOfTrading.com