## MA / Price Cross Strategy

Strategies are published here.

### Re: MA / Price Cross Strategy

PPMA, VIDYA and some other Methods Added to topmost Post.

Another similar strategy, with PPMA and VIDYA can be found here.
viewtopic.php?f=31&t=23836&hilit=MA+Cross

Apprentice
FXCodeBase: Confirmed User

Posts: 20594
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

### Re: MA / Price Cross Strategy

example

Crossover
Cross over, closing price, below the moving average generates Long orders

Thanks and regards
arstechnica

Posts: 48
Joined: Sat Sep 29, 2012 4:25 am

### Re: MA / Price Cross Strategy

Apprentice
FXCodeBase: Confirmed User

Posts: 20594
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

### Re: MA / Price Cross Strategy

Hello,

Can we chose more than 300 period MA, 800 for example?

Thank you
IQFX32

Posts: 7
Joined: Sun Jun 09, 2013 3:21 pm

### Re: MA / Price Cross Strategy

limit increased to 2000.

Apprentice
FXCodeBase: Confirmed User

Posts: 20594
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

### Re: MA / Price Cross Strategy

It dosen't works.
Thank you
IQFX32

Posts: 7
Joined: Sun Jun 09, 2013 3:21 pm

### Re: MA / Price Cross Strategy

Apprentice
FXCodeBase: Confirmed User

Posts: 20594
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

### Re: MA / Price Cross Strategy

Hi,
I tried loading price_ma.lua got an error. "price_ma.lua: 78: unexpected symbol near )"

I'm new just learning how to learn lua programming. But I suppose the 78 is the line number.

This is line 78:-

strategy.parameters:addDouble("MvaLBSens", "Minimal change of MVA to detect trend (in %)", "", 1, 0.000001, 1000000);

I have no idea of what it means. There is a big gap between looking at Guppy's ma's etc,. And other project to learn from that I have found, and this program.

Can someone explain how I can fix this?

Also are there any tutorials with projects that go from beginner to more advanced in small steps? If so where can I find them?

Thanks.

Cheers

Bob NZ

Posts: 2
Joined: Sat Nov 17, 2012 9:15 am

### Re: MA / Price Cross Strategy

Bob, it's actually the line above the one you're referring to. Change
strategy.parameters:addInteger("MvaLB1", "Periods to look back", "", 20, 1, 2000));
to
strategy.parameters:addInteger("MvaLB1", "Periods to look back", "", 20, 1, 2000);
Epsilon

Posts: 1
Joined: Mon Jul 08, 2013 12:39 pm

### Re: MA / Price Cross Strategy

Bug Fixed.

Apprentice
FXCodeBase: Confirmed User

Posts: 20594
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

PreviousNext