Adding a formula to my indicator

 

Hi guys, glad to be apart of the family and looking forward to helping out where i can aswell as being helped haha

In need of some help with my trouble. So as it stands, it reads this for example

Open: 1.59270
High: 1.59320
Low: 1.59248
Close: 1.59251

Although now i would like to add a few things to the bottom.

Open: 1.59270
High: 1.59320
Low: 1.59248
Close: 1.59251

Sell X: 0.00069
Buy X: 0.00003
Body: 0.00019

To get these answers;

Sell X: High - Close (1.59320 - 1.59251 = 0.00069)
Buy X: Close - Low (1.59251 - 1.59248 = 0.00003)
Body: Open - Close (1.59270 - 1.59251 = 0.00019)

Any help would be super appreciated even if its pointing me in the right direction so i can learn to code it myself would be equally appreciated!


cheers

//+------------------------------------------------------------------+
//|                                            Mn Show Past OHLC.mq4 |
//+------------------------------------------------------------------+
#property copyright "Mn"
#property indicator_chart_window

extern int mBarsBack = 3;
extern int mCorner   = 1, 
           mXpos     = 5,
           mYpos     = 2,
           mtextSize = 8;
extern int mCol      = Blue;

//+------------------------------------------------------------------+
int init()
 { 
   for(int i = 0; i < 5; i++)
     {
      ObjectCreate("mOHLC"+i, OBJ_LABEL, 0, 0, 0, 0, 0);
      ObjectSet("mOHLC"+i, OBJPROP_CORNER, mCorner);
      ObjectSet("mOHLC"+i, OBJPROP_XDISTANCE, mXpos);
      ObjectSet("mOHLC"+i, OBJPROP_YDISTANCE, mYpos + i * 15);
      if(mCorner == 2 || mCorner == 3)
        ObjectSet("mOHLC"+i, OBJPROP_YDISTANCE, mYpos + MathAbs(i-4) * 15);
      ObjectSetText("mOHLC+i", " ", mtextSize, "Arial", CLR_NONE);
     }
     
  return(0); 
 }
 
//-----------------------------------------------+ 
int start()
 {
   static int mTime;
   if(Time[0] > mTime)
     {
       ObjectSetText("mOHLC0", DoubleToStr(mBarsBack, 0) + " Bars Back", mtextSize, "Arial", mCol);
       ObjectSetText("mOHLC1", "Open : " + DoubleToStr(Open[mBarsBack], Digits), mtextSize, "Arial", mCol);
       ObjectSetText("mOHLC2", "High : " + DoubleToStr(High[mBarsBack], Digits), mtextSize, "Arial", mCol);
       ObjectSetText("mOHLC3", "Low : " + DoubleToStr(Low[mBarsBack], Digits), mtextSize, "Arial", mCol);
       ObjectSetText("mOHLC4", "Close : " + DoubleToStr(Close[mBarsBack], Digits), mtextSize, "Arial", mCol);
       mTime = Time[0];
     }                              

  return(0);
 }
 
//-----------------------------------------------+
int deinit()
 {
   for(int i = 0; i < 5; i++)
      ObjectDelete("mOHLC"+i);
  
  return(0);
 }

//-----------------------------------------------+


Reason: