NINJA PLATFORM

forex live trades, setups, charts

Moderator: moderators

dinorumble
rank: <50 posts
rank: <50 posts
Posts: 5
Joined: Wed Dec 23, 2009 5:06 am
Reputation: 0
Gender: Male

Postby dinorumble » Sat Jan 02, 2010 9:07 pm

Patch wrote:dinorumble
Are you going to code your autotrader in MT4 or Ninja?
Patch
In VA



I use NinjaTrader. But I'm not a professional programmer so the code might look a little amateurish.

I've coded the indicator and strategy, but I seem to have some bugs. It's probably going to be useless to people at this stage since I've hard coded a lot of the parameters. I'll work on making it more user friendly when I have time but here's the indicator if someone wants to check it out.

Cheers
Attachments
CustomLinearRegressionIndicator.zip
The bars go green when it's time to go long and red when its time to go short. Yellow up means to get ready for a green bar and yellow down means to get ready for a red bar. Alerts will go off only if the channel is in the same direction or flat to the in
(11.07 KiB) Downloaded 41 times

Please add www.kreslik.com to your ad blocker white list.
Thank you for your support.

dinorumble
rank: <50 posts
rank: <50 posts
Posts: 5
Joined: Wed Dec 23, 2009 5:06 am
Reputation: 0
Gender: Male

Postby dinorumble » Wed Jan 06, 2010 8:43 pm

After running some back tests with various parameters including different data-sets (other major pairs and different time periods) , I've decided to use 20 range bars with a linear regression bar period of 200. The 10 range with 60 bar period linear regression worked out well with Eur/Usd in back test but for myself I need to see parameters that work on various datasets to be confident in using a system. If there is anyone that wants to download my automated strategy for backtesting I can post it on here but it is not well commented and has lots of hard-coding parameter changes (meaning that some of the parameters need to be changed directly in the code and some wizard variables are inactive)

kcbnyc
rank: <50 posts
rank: <50 posts
Posts: 26
Joined: Wed Aug 05, 2009 4:59 am
Reputation: 0
Location: Maryland
Gender: None specified

Postby kcbnyc » Fri Jan 08, 2010 3:42 am

dinorumble wrote:After running some back tests with various parameters including different data-sets (other major pairs and different time periods) , I've decided to use 20 range bars with a linear regression bar period of 200. The 10 range with 60 bar period linear regression worked out well with Eur/Usd in back test but for myself I need to see parameters that work on various datasets to be confident in using a system. If there is anyone that wants to download my automated strategy for backtesting I can post it on here but it is not well commented and has lots of hard-coding parameter changes (meaning that some of the parameters need to be changed directly in the code and some wizard variables are inactive)
What hardcoded parameters need to be changed? Also, how would I add my ATM strategy? Thanks for your work!

dinorumble
rank: <50 posts
rank: <50 posts
Posts: 5
Joined: Wed Dec 23, 2009 5:06 am
Reputation: 0
Gender: Male

Postby dinorumble » Fri Jan 08, 2010 7:14 am

kcbnyc wrote:
dinorumble wrote:After running some back tests with various parameters including different data-sets (other major pairs and different time periods) , I've decided to use 20 range bars with a linear regression bar period of 200. The 10 range with 60 bar period linear regression worked out well with Eur/Usd in back test but for myself I need to see parameters that work on various datasets to be confident in using a system. If there is anyone that wants to download my automated strategy for backtesting I can post it on here but it is not well commented and has lots of hard-coding parameter changes (meaning that some of the parameters need to be changed directly in the code and some wizard variables are inactive)
What hardcoded parameters need to be changed? Also, how would I add my ATM strategy? Thanks for your work!



When I coded the automated strategy I modified different parameters to see what would work best for take profit . Instead of writing it so it would be user friendly I wrote it for myself. So for example I wanted to move my stop to break-even once the low of a candle was above my entry by so many pips. Also I played around with my take profit from (1:1 to 1:3 etc.) also tried some code to change my take profit from 1:1 to opposite linear regression line once middle line was reached. As well as some code changing the times that I would place orders.



All these parameters (plus a bunch of others) are written directly in the code and are "commented out" when I don't want to utilize them. If you are familiar with programming then you could probably figure it out but if you're not then it might be pointless to download it.

Here it is....hopefully it works out
Attachments
LinearAutoStrategy.zip
(16.82 KiB) Downloaded 29 times

User avatar
Patch
rank: 500+ posts
rank: 500+ posts
Posts: 941
Joined: Sat Jan 06, 2007 6:13 pm
Reputation: 0
Location: Virginia
Real name: Jeff
Gender: Male
Contact:

Postby Patch » Fri Jan 08, 2010 3:17 pm

dinorumble

First of all, thanks so much for your vision and effort and MT4 programming. I've presently got several pressing issues in the air right now and have not looked at your MT4 file.

Have you put comments along with the code telling what the several hard coded variables are and located? If so, Great; if not, it would be a great help if you could do so.

Patch
In VA
ENOUGH being a Yalie for me Back to the Sea. "What i can lose, i can win" "YES YOU CAN" - dragon33 -"Pick one method and one pair and stick with them until you master it. "The choice is yours - success or failure." TRO

Please add www.kreslik.com to your ad blocker white list.
Thank you for your support.

dinorumble
rank: <50 posts
rank: <50 posts
Posts: 5
Joined: Wed Dec 23, 2009 5:06 am
Reputation: 0
Gender: Male

Postby dinorumble » Fri Jan 08, 2010 3:53 pm

Patch wrote:dinorumble

First of all, thanks so much for your vision and effort and MT4 programming. I've presently got several pressing issues in the air right now and have not looked at your MT4 file.

Have you put comments along with the code telling what the several hard coded variables are and located? If so, Great; if not, it would be a great help if you could do so.

Patch
In VA



Hi Patch,
It's coded for NinjaTrader and it isn't commented very well but when I have some time I will try and make a user friendly version of it.

User avatar
Patch
rank: 500+ posts
rank: 500+ posts
Posts: 941
Joined: Sat Jan 06, 2007 6:13 pm
Reputation: 0
Location: Virginia
Real name: Jeff
Gender: Male
Contact:

Postby Patch » Fri Jan 08, 2010 6:42 pm

dinorumble

or if you just take a second and stick in a few comments on the key variables.

I know you must be learning a lot about programming.

Patch
In VA
ENOUGH being a Yalie for me Back to the Sea. "What i can lose, i can win" "YES YOU CAN" - dragon33 -"Pick one method and one pair and stick with them until you master it. "The choice is yours - success or failure." TRO

dchappy
rank: 500+ posts
rank: 500+ posts
Posts: 832
Joined: Sat Feb 14, 2009 8:48 pm
Reputation: 3
Gender: Male

Postby dchappy » Thu Jan 28, 2010 4:30 pm

This is the simple set-up I'm testing in the MT4 contest .

A combination of TRO's " Rat " & Monolisa's " Squiggly "

Just wait for the Sema and then trade away from it .

Time will tell :)

(Template is attached if you'ld like to follow along )
Attachments
raswilly.gif
raswilly.gif (16.38 KiB) Viewed 261 times
ra-swiggly.zip
(2.37 KiB) Downloaded 56 times

User avatar
tmanbone
rank: 500+ posts
rank: 500+ posts
Posts: 723
Joined: Sun Nov 15, 2009 3:52 am
Reputation: 0
Gender: Male

Postby tmanbone » Fri Jan 29, 2010 12:31 am

dchappy, I've learn a little trick on MT4 about setting up like your charts on Ninja, if you set your bars to black you will only see the heiken ashi, but who am I to be giving you any pointers, keep up the good work, still studying your methods. Thanks,
"The simplicity of the markets is it's greatest disguise"

T

dchappy
rank: 500+ posts
rank: 500+ posts
Posts: 832
Joined: Sat Feb 14, 2009 8:48 pm
Reputation: 3
Gender: Male

Postby dchappy » Fri Jan 29, 2010 9:02 am

tmanbone wrote:dchappy, I've learn a little trick on MT4 about setting up like your charts on Ninja, if you set your bars to black you will only see the heiken ashi, but who am I to be giving you any pointers, keep up the good work, still studying your methods. Thanks,


Yes , I see what your saying , however right now I'm trying to watch where each new bar closes .

I would prefer to use the range bars but haven't found a "free " one yet for mt4 ( I'm kind of cheeep :lol: )

And , feel free to offer pointers ...we all stand on each others shoulders here..

Please add www.kreslik.com to your ad blocker white list.
Thank you for your support.


Return to “forex”