Navigation

    Backtrader Community

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    For code/output blocks: Use ``` (aka backtick or grave accent) in a single line before and after the block. See: http://commonmark.org/help/

    Return order executed price in def next (self)?

    General Code/Help
    2
    2
    406
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Y
      YYF last edited by

      First of all thanks for creating backtrader. This relieves my work a lot in trading.

      Have a question about stop loss in strategy. Watched the post about stop trading link text and suggest to include stop loss in def notify_order. But because i define all strategy in def next, so is it possible to get the buy execution price in def next area?

      Thanks a lot. Still learning how to use this great platform :)

      B 1 Reply Last reply Reply Quote 0
      • B
        backtrader administrators @YYF last edited by

        @yyf said in Return order executed price in def next (self)?:

        is it possible to get the buy execution price in def next area?

        Store it when received in notify_order and use the stored value in next

        1 Reply Last reply Reply Quote 1
        • 1 / 1
        • First post
          Last post
        Copyright © 2016, 2017, 2018, 2019, 2020, 2021 NodeBB Forums | Contributors