code: def parse_args():
      parser = argparse.ArgumentParser(
          description="Showcase for Order Execution Types"
      )
  
      parser.add_argument(
          "--infile",
          "-i",
          required=False,
          default="../../datas/2006-day-001.txt",
          help="File to be read in",
      )
  
      parser.add_argument(
          "--csvformat",
          "-c",
          required=False,
          default="bt",
          choices=[
              "bt",
              "visualchart",
              "sierrachart",
              "yahoo",
              "yahoo_unreversed",
          ],
          help="CSV Format",
      )
  
      parser.add_argument(
          "--fromdate",
          "-f",
          required=False,
          default=None,
          help="Starting date in YYYY-MM-DD format",
      )
  
      parser.add_argument(
          "--todate",
          "-t",
          required=False,
          default=None,
          help="Ending date in YYYY-MM-DD format",
      )
  
      parser.add_argument(
          "--plot",
          "-p",
          action="store_true",
          required=False,
          help="Plot the read data",
      )
  
      parser.add_argument(
          "--plotstyle",
          "-ps",
          required=False,
          default="bar",
          choices=["bar", "line", "candle"],
          help="Plot the read data",
      )
  
      parser.add_argument(
          "--numfigs",
          "-n",
          required=False,
          default=1,
          help="Plot using n figures",
      )
  
      parser.add_argument(
          "--smaperiod",
          "-s",
          required=False,
          default=15,
          help="Simple Moving Average Period",
      )
  
      parser.add_argument(
          "--exectype",
          "-e",
          required=False,
          default="Market",
          help=(
              "Execution Type: Market (default), Close, Limit,"
              " Stop, StopLimit"
          ),
      )
  
      parser.add_argument(
          "--valid",
          "-v",
          required=False,
          default=0,
          type=int,
          help="Validity for Limit sample: default 0 days",
      )
  
      parser.add_argument(
          "--perc1",
          "-p1",
          required=False,
          default=0.0,
          type=float,
          help=(
              "%% distance from close price at order creation"
              " time for the limit/trigger price in Limit/Stop"
              " orders"
          ),
      )
  
      parser.add_argument(
          "--perc2",
          "-p2",
          required=False,
          default=0.0,
          type=float,
          help=(
              "%% distance from close price at order creation"
              " time for the limit price in StopLimit orders"
          ),
      )
  
      return parser.parse_args()
  
file_path: backtrader/samples/order-execution/order-execution.py
imports: from __future__ import absolute_import, division, print_function, unicode_literals
  import argparse
  import datetime
  import os.path
  import time
  import sys
  import backtrader
  import backtrader.feeds
  import backtrader.indicators
label_desc: Use image node_id 3 for calling a global function with example usage: parse_args() and returns: parser