Navigation

    Backtrader Community

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    1. Home
    2. feile922
    For code/output blocks: Use ``` (aka backtick or grave accent) in a single line before and after the block. See: http://commonmark.org/help/
    F
    • Profile
    • Following 0
    • Followers 0
    • Topics 1
    • Posts 1
    • Best 0
    • Groups 0

    feile922

    @feile922

    0
    Reputation
    184
    Profile views
    1
    Posts
    0
    Followers
    0
    Following
    Joined Last Online

    feile922 Unfollow Follow

    Latest posts made by feile922

    • It seems a bug("RateOfChange100") in momentum.py, which doesn't pass period value to ROC

      I reviewed the code("RateOfChange100") and found it doesn't pass period to ROC.

      def __init__(self):
          self.l.roc100 = 100.0 * ROC(self.data)    # not pass period to ROC
          super(RateOfChange100, self).__init__()
      

      Correct it:

      def __init__(self):
          self.l.roc100 = 100.0 * ROC(self.data, period=self.p.period)
          super(RateOfChange100, self).__init__()
      

      If there is anything I misunderstand, pls feel free to let me know.
      -Le

      posted in Indicators/Strategies/Analyzers
      F
      feile922