Announcement

Collapse
No announcement yet.

Price Volume Trend

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Price Volume Trend

    The Price Volume Trend indicator calculates the percent change in price from the previous bar’s close to the close of the current bar. The volume is multiplied by this percentage and added to a running total. The running total is plotted on the chart.


    Can you create it please ?

  • #2
    PVT

    Here's the Metastock PVT formula

    PVT = (((C-ref(C,-1)) / ref(C,-1)) * V) + I

    Where:

    C = Close
    ref(C,-1) = Yesterday's Close
    V = Volume of the day
    I = Yesterday's Price Volume Trend


    It can be easy to implement it in esignal.

    Kind regards

    Comment


    • #3
      pbereau
      The enclosed efs will replicate the metastock code
      Alex

      PHP Code:
      function preMain() {
          
      setPriceStudy(false);
          
      setStudyTitle("PVT");
          
      setCursorLabelName("PVT");      
      }

      var 
      PVT null;
      var 
      PVT_1 null;

      function 
      main() {
          
          if(
      getBarState()==BARSTATE_NEWBAR){
              
      PVT_1 PVT;
          }

          
      PVT = (((close()-close(-1))/close(-1))*volume())+PVT_1;


          return 
      PVT;

      Comment

      Working...
      X