Need Help in writing INDICATOR

 

I am trying to write an indiactor that wil plot a horizonal lines at the past DAILY Average High and Low points on the chart.

I have no background or idea how to write this. I have looked at mant indicators on the forum to try to get an idea but, I get confused

I am not sure how to wite in code take the last 5 days highs - their opens than add tha to yesterdays close to get the current averge high.

Also to do the same for the lows. If this works possibly use this on the WEEKLY and MONTHLY charts or vary theamount of bars to use.

I hope this gives a good view in what I am trying to do. I have used several different parts of different pivot indicators to help me start.

I have attatched what I have.

jim

Files:
 
good luck. still learning myself or I would try to help.