Hey everyone, this is my first day on quantopian, and while I have experience using python from a numerical methods course I took, I would consider myself very beginner. I was trying to build a simple algorithm that would take a long position anytime price moves above a EMA and a short position when price moves below, so essential switching back and forth. I have modeled my algorithm after the futures tutorial lesson 12, which I have linked. I finally worked out the bugs so that the backtesting actually works, but my problem is the algorithm never takes any positions.
Disclaimer: As I said this is my first day, and I pretty much copied and manipulated the tutorial code, so some variable names might not make too much sense, but that is why I am attaching the tutorial link. If the whole thing is a jumbled mess that can't be fixed I will take that as a helpful answer!