For code/output blocks: Use ``` (aka backtick or grave accent) in a single line before and after the block. See:

Beginner setup | Using & Accessing data feed(s)

  • Hey backtraders,

    Clearly I'm new here but I'm open to learning! I'm looking to get some help with some basic setup that I think most of you were able to hurdle. Following the Quickstart Guide I was able to get set up fairly easy. Next, Adding a Data Field this is where I struggled to understand how we were creating a data feed.

    if __name__ == '__main__':
        # Create a cerebro entity
        cerebro = bt.Cerebro()
        # Datas are in a subfolder of the samples. Need to find where the script is
        # because it could have been called from anywhere
        modpath = os.path.dirname(os.path.abspath(sys.argv[0]))
        datapath = os.path.join(modpath, '../../datas/orcl-1995-2014.txt')

    The quick start guide never explained how we are downloading csv or txt files from any of the data feeds. So, This is where I'm looking to get some help from within this commuity. Can someone kindly show me how they are configuing their data feeds? Just to be clear. The reason I'm here is mainly to learn about python through trading. I'd love to get a better understanding of python along with coding up some of my stragegies.

    Let me know if you need me to give more details or whatever. I also have a basic understanding of functional programming

  • Not sure how to delete this post but I figured this out. I'm just getting started and was able to solve this problem. All i needed to do was step away for a second and come back to the problem.

    Current fix: the .txt file that was being referenced was within in the backtraders github repo. I'm still not certain how you are pulling data back to your computer but its still early in this learning process.... I'm actually getting excited after making such progress in one day

Log in to reply