hi, it's possible to study equity and entry in the market when equity cross over Sma (it's an example)
How can i do it?
Enter signal cross equity
- TJ
- Posts: 7743
- Joined: 29 Aug 2006
- Location: Global Citizen
- Has thanked: 1033 times
- Been thanked: 2222 times
Re: Enter signal cross equity
hi, it's possible to study equity and entry in the market when equity cross over Sma (it's an example)
How can i do it?
You have to give a more detailed description.
First step -- draw a diagram to illustrate your idea
2nd step -- draw a flow chart
Next step -- write out your strategy in a step-by-step logic
Re: Enter signal cross equity
this is the chart and his equity line
i want enter position (long ) when Momentum of line equity(10 period ago) is > of line equity line at this moment
how can i do it?
- TJ
- Posts: 7743
- Joined: 29 Aug 2006
- Location: Global Citizen
- Has thanked: 1033 times
- Been thanked: 2222 times
Re: Enter signal cross equity
If you can imagine it, you can do it.i give you another example
this is the chart and his equity line
i want enter position (long ) when Momentum of line equity(10 period ago) is > of line equity line at this moment
how can i do it?
Next steps -- draw a logic flow chart and write out your strategy in a Step-by-Step logic.
For example:
1. get equity value
2. calculate equity moving average (EMA)
3. compare EMA to . . . .
4. If BUY CONDITION = TRUE then BUY 1 next bar at market
See post #6
viewtopic.php?t=11713
- TJ
- Posts: 7743
- Joined: 29 Aug 2006
- Location: Global Citizen
- Has thanked: 1033 times
- Been thanked: 2222 times
Re: Enter signal cross equity
I dont understand
You say" if true the buy..."
...
If BUY CONDITION = TRUE then buy...
- TJ
- Posts: 7743
- Joined: 29 Aug 2006
- Location: Global Citizen
- Has thanked: 1033 times
- Been thanked: 2222 times
Re: Enter signal cross equity
Ok..but how i code automatic signal to code it?
( automatic in powerlanguage"
It is possible to build bridge from 2 chart signal?
First, you have to write out your logic as the example I posted above.
NEXT... convert the logic to EasyLanguage codes.
BUT you must write out your logic in detail.
Right now you have a concept.
The concept is in your head.
I cannot read your head.
You have to write out your logic in STEP-BY-STEP detail.
Re: Enter signal cross equity
I'm sorry but the problem is that I can not explain myself since I speak English with the translator..the problem is not to create the logic
How can I tell the system not to enter when the chart signals are there but to enter only when the equity study?
If equity is created through trade signals, I do not want to trade but wait for the equity study
did you understand what I mean?
How can I tell the system not to enter when the chart signals are there but to enter only when the equity study?
If equity is created through trade signals, I do not want to trade but wait for the equity study
did you understand what I mean?
Re: Enter signal cross equity
Hi turbofib,
Maybe what you need is to use is a flag. I mean,
Maybe what you need is to use is a flag. I mean,
Code: Select all
Vars: Flag(false);
If Momentum of line equity(10 period ago) is > of line equity line at this moment then
Flag = true;
else
Flag = false;
If Condition (the entry conditions of your system) and Flag = true then
buy .......
Re: Enter signal cross equity
Mazinguer thank but the problem is another ..
The problem is sending the realtime signals to the connected broker (Example Interactive Broker)
The chart generates signals that create the equity...
But these signals contain "buy (Condition), Or sell (Condition) and in this signal the trade is executed because multichart is attached to the broker
Now if i code
"
If Momentum of line equity(10 period ago) is > of line equity line at this moment then
Flag = true;
else
Flag = false;
If Condition (the entry conditions of your system) and Flag = true then
buy .......
"
It is correct but I have already traded before in the signal,instead I want to trade the signal after the study of the equity
The problem is sending the realtime signals to the connected broker (Example Interactive Broker)
The chart generates signals that create the equity...
But these signals contain "buy (Condition), Or sell (Condition) and in this signal the trade is executed because multichart is attached to the broker
Now if i code
"
If Momentum of line equity(10 period ago) is > of line equity line at this moment then
Flag = true;
else
Flag = false;
If Condition (the entry conditions of your system) and Flag = true then
buy .......
"
It is correct but I have already traded before in the signal,instead I want to trade the signal after the study of the equity
Re: Enter signal cross equity
Maybe you can use Mazinguer's suggestion and global variables.
On a chart that does not trade you can put your system and with GV you can pass flag to a chart that submits buy-sell orders
On a chart that does not trade you can put your system and with GV you can pass flag to a chart that submits buy-sell orders
Re: Enter signal cross equity
This answer is a cut and paste from the net: ...
... so, in Multicharts 64 bit you have GV already installed and can use them simply with
in the sending signal and
in the receiving signal.
Look in PowerLanguage editor.
Hope this helps.
Massimo
Mike,
Not sure what help you wanted but using global variables itself is very easy. Presuming that GV is installed within Multicharts, here's some code I use to send data from one chart to another:
Indicator in the sending chart:
In the receiving chart strategy or indicator uses:Code: Select all
if LastBarOnChart and barstatus(1)=2 then
begin
GVSetDouble(1,CumVol);
GVSetDouble(2,CumVolAvg);
GVSetDouble(3,BarNumber);
end;
1, 2, and 3 are the addresses for storing the variables. You can also do it by name using different syntax.Code: Select all
CumVol=GVGetDouble(1);
CumVolAvg=GVGetDouble(2);
KaseBarNumber=GVGetDouble(3);
Paul
... so, in Multicharts 64 bit you have GV already installed and can use them simply with
Code: Select all
GVSetBoolean(ElementLocation,GVValue)
GVSetFloat(ElementLocation,GVValue)
GVSetDouble(ElementLocation,GVValue)
GVSetInteger(ElementLocation,GVValue)
Code: Select all
GVGetBoolean(ElementLocation)
GVGetFloat(ElementLocation)
GVGetDouble(ElementLocation)
GVGetInteger(ElementLocation)
Look in PowerLanguage editor.
Hope this helps.
Massimo