class_docstr: This strategy is loosely based on some of the examples from the Van
  K. Tharp book: *Trade Your Way To Financial Freedom*. The logic:
  
    - Enter the market if:
      - The MACD.macd line crosses the MACD.signal line to the upside
      - The Simple Moving Average has a negative direction in the last x
        periods (actual value below value x periods ago)
  
   - Set a stop price x times the ATR value away from the close
  
   - If in the market:
  
     - Check if the current close has gone below the stop price. If yes,
       exit.
     - If not, update the stop price if the new stop price would be higher
       than the current
code: def next(self):
      dt = self.data.datetime.date()
  
      portfolio_value = self.broker.get_value()
      print(
          "%04d - %s - Position Size:     %02d - Value %.2f"
          % (
              len(self),
              dt.isoformat(),
              self.position.size,
              portfolio_value,
          )
      )
  
      data_value = self.broker.get_value([self.data])
  
      if self.p.use_target_value:
          print(
              "%04d - %s - data value %.2f"
              % (len(self), dt.isoformat(), data_value)
          )
  
      elif self.p.use_target_percent:
          port_perc = data_value / portfolio_value
          print(
              "%04d - %s - data percent %.2f"
              % (len(self), dt.isoformat(), port_perc)
          )
  
      if self.order:
          return  # pending order execution
  
      size = dt.day
      if (dt.month % 2) == 0:
          size = 31 - size
  
      if self.p.use_target_size:
          target = size
          print(
              "%04d - %s - Order Target Size: %02d"
              % (len(self), dt.isoformat(), size)
          )
  
          self.order = self.order_target_size(target=size)
  
      elif self.p.use_target_value:
          value = size * 1000
  
          print(
              "%04d - %s - Order Target Value: %.2f"
              % (len(self), dt.isoformat(), value)
          )
  
          self.order = self.order_target_value(target=value)
  
      elif self.p.use_target_percent:
          percent = size / 100.0
  
          print(
              "%04d - %s - Order Target Percent: %.2f"
              % (len(self), dt.isoformat(), percent)
          )
  
          self.order = self.order_target_percent(target=percent)
  
file_path: backtrader/samples/order_target/order_target.py
imports: from __future__ import absolute_import, division, print_function, unicode_literals
  import argparse
  from datetime import datetime
  import backtrader
label_desc: Use image node_id 3 for calling the TheStrategy obj's underlying member method code with example usage: obj.next() without return types