×

[PR]この広告は3ヶ月以上更新がないため表示されています。ホームページを更新後24時間以内に表示されなくなります。

NinjaTrader Support Forum  

Go Back   NinjaTrader Support Forum > Links and Downloads Manager
Welcome, micpapa.
You last visited: Yesterday at 11:38 PM
Private Messages: Unread 0, Total 0.
NinjaTrader User CP FAQ Members List New Posts Quick Links Log Out

Categories Add Entry   2.3.0

Version 7 Strategies
Share NinjaScript strategies compatible with NinjaTrader Version 7. Post, search and download them here!

Sort by
Keyword Filter

  Entries Show full/short entries
  Avoid Same Bar Whipsaws v1.1 Left click: open entry/Right click: save entry

View enlarged thumbnail
  Exported using NT Version 7.0.0.18

################################

v 1.1 - modified December 15, 2009

Summary of changes
  1. Changed defaults for targets and stops, after queries indicated that most users were using the default 1 tick while evaluating v1.0, which naturally resulted in 1 bar whipsaws.
  2. Added remarks to better explain the code.
  3. Added notes to initial description, to explain what the strategy does.
################################

Released with no copyright.

It is free to use for any purpose.

This is demonstration of how to set up a strategy that will not whipsaw trades on the same bar as entry. I seemed to have that problem with a lot of the strategies that I wrote that were designed to reverse in the market if conditions reversed, which is why I wrote this, as an example template.

The strategy keeps you always in the market until either:
  1. The profit target is hit; or
  2. The stop loss is hit; or
  3. Market conditions reverse.
Either of the first 2 exit conditions takes you flat; the 3rd condition causes an immediate reversal from long to short, or short to long, as the case may be.

To stay always in regardless, use excessively large stops and targets.

By using this code, you accept all responsibility for any results that may occur. This is not a recommendation to use the code to trade any equity in a live market.

Any investments, trades and/or speculations using this code are made solely at your own risk, financial or otherwise. Results will be dependent on market conditions, timing and your trading style.

If you disagree with these conditions, please do NOT use the code.

########################################################################
!!!!! Translation: You are responsible for your own investment decisions. Not anyone else. YOU !!!!!
########################################################################


To Import
1. Download the attached file to your desktop
2. From the Control Center window select the menu File > Utilities > Import NinjaScript
3. Select the downloaded file
 
[Send to Friend] Suggest other entries I might like
Submitted by koganam Find all entries from this user
07-14-2010
4.29 Kbytes Hits 1528
  Bar Breakout 1 input Left click: open entry/Right click: save entry 4 *
Exported with NinjaTrader 7.0.0.18

This system goes long at the highest high of the last x bars and goes short at the lowest low of the last x bars.

IMHO there is very little example code available for those new to NT and programming. Hopefully this will change soon.
 
[Send to Friend] Suggest other entries I might like
Submitted by MP948 Find all entries from this user
07-14-2010
4.66 Kbytes Hits 478
 [1 ratings, 1 comments]
  Combining DMI and Moving Average Strategy from the August 2009 issue of S&C Left click: open entry/Right click: save entry 4 *

View enlarged thumbnail
  Exported using NinjaTrader 7.0.0.18

Description
The trading system as discussed in the August 2009 S&C article titled "Combining DMI And Moving Average For a EUR/USD Trading System" by Rombout Kerstens.

To Import
1. Download the attached file to your desktop
2. From the Control Center window select the menu File > Utilities > Import NinjaScript
3. Select the downloaded file
 
[Send to Friend] Suggest other entries I might like
Submitted by NinjaTrader_Josh Find all entries from this user
07-14-2010
5.08 Kbytes Hits 1204
 [1 ratings, 1 comments]
  dayOfWeekOptimizer Left click: open entry/Right click: save entry

View enlarged thumbnail
  Exported using NinjaTrader 7.0.0.18

Description
This strategy illustrates how you might optimize a non-integer property. The public property dayOfWeekInt can be optimized. This property assigns a value to the string which is checked for a simple enter condition.


To Import
1. Download the attached file to your desktop
2. From the Control Center window select the menu File > Utilities > Import NinjaScript
3. Select the downloaded file
 
[Send to Friend] Suggest other entries I might like
Submitted by NinjaTrader_RyanM Find all entries from this user
07-14-2010
1.34 Kbytes Hits 323
  Divergence Pattern Left click: open entry/Right click: save entry 5 *

View enlarged thumbnail
  Exported using NinjaTrader 7.0.0.18

Description

This strategy uses divergence pattern to identify entry into a stock. I use CCI, MACD & Ergodic indicator, any 2 of 3 indicators forming divergence provides confirmation to avoid false positive. The strategy is based on custom indicator in which you can select the indicator (from range of indicators) to identify divergence pattern with Price.

The best results are obtained when I use daily data and CCI(40), MACD (12,9,26) & Ergodic(40,12).

Check for urself and please provide your feedback...

To Import
1. Download the attached file to your desktop
2. From the Control Center window select the menu File > Utilities > Import NinjaScript
3. Select the downloaded file
 
[Send to Friend] Suggest other entries I might like
Submitted by isitpossible Find all entries from this user
07-14-2010
38.29 Kbytes Hits 1169
 [1 ratings, 1 comments]
  Elder Impulse System Left click: open entry/Right click: save entry 1 *

View enlarged thumbnail
  [IMG]file:///C:/Users/apivarnik/Downloads/vervoortma.jpg[/IMG]Exported using NinjaTrader 7.0.0.18

Description
Elder Impulse trading system. Includes support for a second, higher time frame period for determining trend and momentum. The background is painted pink when the higher time frame trend and momentum is down, and green when it is up. The rules for entering and exiting a trade are described here on Investopedia and Stockcharts.com.

To Import
1. Download the attached file to your desktop
2. From the Control Center window select the menu File > Utilities > Import NinjaScript
3. Select the downloaded file An implementation of the
 
[Send to Friend] Suggest other entries I might like
Submitted by shodson Find all entries from this user
07-14-2010
5.88 Kbytes Hits 1046
 [1 ratings, 1 comments]
  Grid Buy Strategy Left click: open entry/Right click: save entry 1 *

View enlarged thumbnail
  Exported using NinjaTrader 7.0.0.18

Description
Grid Stop Buy
v 1.0. beta April 2010 To be implemented before using it with real money.

This strategy is inspired by the 敵rid Trading methodology (details can be found on web) , more often used for forex trading.
The code is only suitable for the buy side, while the sell side should be reversed and still to be coded.

Strategy:
The grid trading strategy uses two sub-accounts (one for buy side and one for sell side) to enter a series of stop orders (grid) at pre-determined levels, each at the same distance level.
Once in position, the order has a take profit already incorporated (usually at or near the next buy order).
Target of this technique, when used in conjunction with the sell side, is to profit on any market movement inside the grid.

Code:
The code creates 21 buy stop orders above the 鉄tart Level price, that must be set above 1.

The 鉄teps value defines the distance of the stop orders and must be set as number of ticks.

The 典P (take profit) could be set at the same 鉄teps value (original grid trading version) or could be chosen on a different level.

Once in position, the code does not generate any further entry on the same level, until the original order is not closed (profit target), this is done to prevent multiple orders/position on the same price.

When positions are closed (this means buy and take profit) a new stop order is placed when the price re-enter below the single zone level (see images).

Code is completely free to be implemented but I壇 rather prefer, for any modification from the original, to be shared here and become available to anyone.

Possible implementation could be:
-semplification of some code rows (I知 not a C# expert, so, probably many lines could be recoded more easily).
-an indicator could be added to show grid price levels.
-I致e seen trouble on some stop orders entry when price hits precisely the level, sometime the order is cancelled instead of executed. Reason could be in the way the levels are calculated and this must be explorated and tested deeply.
- See if superimposition of new buy entry and previous take profit level could be avoided (sometime there are some).

Hope this could be useful and become something tradable for people interested in this methodology.

Try this on real market on simulation account for testing purpose. Any comment is welcome.

P.S. I知 Italian and apologize if my English not always is so clear.


To Import
1. Download the attached file to your desktop
2. From the Control Center window select the menu File > Utilities > Import NinjaScript
3. Select the downloaded file
 
[Send to Friend] Suggest other entries I might like
Submitted by MAX Find all entries from this user
07-14-2010
3.16 Kbytes Hits 614
 [1 ratings, 1 comments]
  LONG SHORT Toolbar Buttons Left click: open entry/Right click: save entry

View enlarged thumbnail
  This strategy will add buttons to the chart toolbar to sell or buy 1 lot but only when certain condition is true.

By default the condition to buy is that Price has to close above the prior two bar.

Anything can be changed in the script so each trader can define his own discretionary entry and exit condition.

Please give input what do you think can be enhanced...
 
[Send to Friend] Suggest other entries I might like
Submitted by tradereight Find all entries from this user
10-06-2011
7.62 Kbytes Hits 56
Keywords: discretionary
  Multi time period backtest framework for Strategy Analyzer Left click: open entry/Right click: save entry

View enlarged thumbnail
  Exported using NinjaTrader 7.0.0.18

Description
This is a multi time period back-tester that can help give more accurate results in Strategy Analyzer, especially if using a high time period like 5min bars or using Limit orders for a better fill price, and stops. Run this using your strategy's normal time period. Orders are submitted to the secondary time period (ie 1min or 200tick) for more "granularity" when processing Limit orders and stops. This frame work was originally written for the ES market (e-mini SP500), so make appropriate adjustment for other markets. Includes: Spaces for multiple order conditions, 3 Market orders && profit targets w/ Stoploss, 2 Limit orders && profit targets w/ Stoploss, Order entry time limit 6:00a-1:43p, Print commands are for debugging.
Helpful links;
http://www.ninjatrader-support.com/vb/showthread.php?t=6652
http://www.ninjatrader-support2.com/vb/showthread.php?t=3220
http://www.ninjatrader-support.com/HelpGuideV6/MultiTimeFrameInstruments.html

To Import
1. Download the attached file to your desktop
2. From the Control Center window select the menu File > Utilities > Import NinjaScript
3. Select the downloaded file
 
[Send to Friend] Suggest other entries I might like
Submitted by zacharydw00 Find all entries from this user
07-14-2010
4.36 Kbytes Hits 633
  Percentage Trailing Stop within OnBarUpdate Left click: open entry/Right click: save entry
Exported using NinjaTrader 7.0.0.18

Description
One of the surprising results of backtesting was how well a simple percentage trailing stop can keep me in large moves. But, if there was some way to have that percentage trailing stop exit trigger some "exit routine" that would be better than simpling exiting the trade.

So with help from Josh and Ben I have now a percentage trailing stop script that is within OnBarUpdate so that when the trailing stop is hit, I can do something like THEN look for a certain type of exit. The next post will have a demonstration of what I mean.

This script uses the output window to track how the trailing stop is working and shows it's values.

To Import
1. Download the attached file to your desktop
2. From the Control Center window select the menu File > Utilities > Import NinjaScript
3. Select the downloaded file
 
[Send to Friend] Suggest other entries I might like
Submitted by sauer11155 Find all entries from this user
07-14-2010
1.45 Kbytes Hits 390
  PipsTrail Left click: open entry/Right click: save entry
Simple strategy with trail stop mechanism (often called snake). Best to use on a day time frame.  
[Send to Friend] Suggest other entries I might like
Submitted by daglas Find all entries from this user
05-19-2011
1.35 Kbytes Hits 138
Keywords: stop trail
  Price Breakout from rectangular Base on Volume Left click: open entry/Right click: save entry 1 *

View enlarged thumbnail
  Exported using NinjaTrader 7.0.0.18

Description
Custom Indicator identifies stocks which breakout of rectangular base with volume

Best results achieved with Chandelier Stop = 3 and ATR = 14, do not forget to set TrailingStopPct = 0.

I hope this works for you, try it and provide your suggestions....

To Import
1. Download the attached file to your desktop
2. From the Control Center window select the menu File > Utilities > Import NinjaScript
3. Select the downloaded file
 
[Send to Friend] Suggest other entries I might like
Submitted by isitpossible Find all entries from this user
07-14-2010
13.15 Kbytes Hits 735
 [1 ratings, 1 comments]
  Price Zone Oscillator as published in June 2011's Stocks and Commodities Magazine Left click: open entry/Right click: save entry

View enlarged thumbnail
  Exported using NT Version 7.0.1000.4

Description
The Price Zone Oscillator strategy was published in the June 2011 S&C article authored by Walid Khalil and David Steckler titled "Entering the Price Zone".

To Import
1. Download the attached file to your desktop
2. From the Control Center window select the menu File > Utilities > Import NinjaScript
3. Select the downloaded file
 
[Send to Friend] Suggest other entries I might like
Submitted by NinjaTrader_Josh Find all entries from this user
06-14-2011
5.40 Kbytes Hits 254
  RandomTrader backtest tool Left click: open entry/Right click: save entry
Exported using NinjaTrader 7.0.0.18

Description
1. Get a feel for optimal trade parameters by randomizing some or all of the trade settings.

2. Time of entry: this should be any number from 1 through 380, the minutes of the trading session (minus 10 minutes).

3. To enter a fixed (non-random) value, put in the same number in 僧in and 僧ax?

For example, you want the trade to be taken at minute # 200 of the trading session. Each of 禅ime of Daily Entry Max and 禅ime of Daily Entry Min should be set to 200.

4. To enter a randomized value, type in the range from which you want the random value to be selected.

For example, you want the trade to be taken randomly within the first half hour of the session, type in 禅ime of Daily Entry Max = 30, and 禅ime of Daily Entry Min = 1.

5. Random long/short trigger. To randomize the long/short decision, select 奏rue for each of the 禅radeLong and 禅radeShort?

6. Note the parameters remain the same throughout one run (i.e., for each push of the 礎acktest button), they are not re-generated for each individual trade.

7. 前ne trade in X bars? Use this only if you want to take a trade less frequently than once per day. Otherwise this should be kept at 0.

To Import
1. Download the attached file to your desktop
2. From the Control Center window select the menu File > Utilities > Import NinjaScript
3. Select the downloaded file
 
[Send to Friend] Suggest other entries I might like
Submitted by Dan Leontieff Find all entries from this user
07-14-2010
2.82 Kbytes Hits 168
  RSI with RSI as published in January 2011's Stocks and Commodities magazine Left click: open entry/Right click: save entry

View enlarged thumbnail
  Exported using NT Version 7.0.0.23

Description
The RSI with RSI strategy was published in the January 2011 S&C article authored by Peter Konner titled "Combining RSI With RSI".

To Import
1. Download the attached file to your desktop
2. From the Control Center window select the menu File > Utilities > Import NinjaScript
3. Select the downloaded file
 
[Send to Friend] Suggest other entries I might like
Submitted by NinjaTrader_Josh Find all entries from this user
01-02-2011
5.30 Kbytes Hits 629
 



 
Category
 
Forum Jump

All times are GMT +7. The time now is 01:45 AM.