MQL4 - automated forex trading   /  

Forum

Login | Register | Language: ru cn en
Freelancer services needed to perform 150+ jobs of traders

I want to modify weekly pivots indicator to plot pivots in the past

Back to topics list To post a new topic, please log in or register
avatar
62
edas 2009.11.09 19:51
 
Hello, I have indicator which plots weekly Pivot/Support/Resistance (it is modified from ready to use indicator).. I want modify this indicator to plot Pivots/Support/Resistance in the past. The reason is that I want to examine Pivots action more closely and create trading strategy based on that pivots. I need to create cycle, which looks for weekly data in the past. Could you help ? Or maybe you have ready indicator ? Thanks, Edward
Attached files:
  autompivot_multi_weekly.mq4  (7.00 KB)
 
Mathematics in Trading: How to Estimate Trade Results
We all are aware of that "No profit obtained in the past will guarantee any success in future". However, it is still very actual to be able to estimate trading systems. This article deals with some simple and convenient methods that will help to estimate trade results.
avatar
223
Jellybean 2009.11.10 09:33 #
 
edas:
Hello, I have indicator which plots weekly Pivot/Support/Resistance (it is modified from ready to use indicator).. I want modify this indicator to plot Pivots/Support/Resistance in the past. The reason is that I want to examine Pivots action more closely and create trading strategy based on that pivots. I need to create cycle, which looks for weekly data in the past. Could you help ? Or maybe you have ready indicator ? Thanks, Edward

Hi Edward


The indicator you are trying to modify draws the pivot lines as objects, so it is an extra job to draw the lines for older data and the number of objects (lines) grows as time passes. An alternative approach is to use indicator buffers so they will be drawn for the whole chart. Fortunately, I have already coded such a pivot point indicator. Some time ago I uploaded one for daily pivots into the codebase (http://www.mql5.com/en/code/8685). I see your indicator is for weekly pivots so I will attach mine for weekly pivots.

My motivation in this forum is to learn and help other people learn, but in this case modifying the indicator you are working with would be like starting again. I urge you to read the code and ask any questions to help understand it.


Cheers

Jellybean

Attached files:
  pivotpointsweekly.mq4  (8.06 KB)
 
avatar
62
edas 2009.11.11 19:41 #
 
Thanks, Jellybean. I modified my indicator so it could show pivots several weeks ago (but only one week). So I compare two indicators results. Some weeks results are are idenfical, some weeks different. Perhaps because they use different functions to collect data. Thanks again for indicator. I also attached my indicator. It is not completed yet: it is necessary to input which week data (pivots/s/r) you want to look.
Attached files:
  pivot_weeks_ago.mq4  (7.26 KB)
 
avatar
223
Jellybean 2009.11.12 09:15 #
 

Hi Edward


I tried both indicators and they each give the same results as each other on my MT4. I have had only a quick look at your and my weekly pivot indicators and I can see only one difference that may be significant.

- In my indicator I use the values from the chart and look for the bars where the week changed. I then use iHighest() & iLowest() to determine the high and low and the previous bar close for the weekly close.

- In your indicator you use the weekly data directly.

I suspect that sometimes they are different because I have seen that sometimes the daily data is different from what can be seen on shorter timeframes.


The forumale for R2, R3, S2 and S3 appear different but they are mathematically the same.


Cheers

Jellybean


 
avatar
14
shakeel353 2010.03.19 22:25 #
 

if you have done please also give it to me to examin the past pivot activity of the pivot thank you

 
Back to topics list  

To add comments, please log in or register