Some nifty code there.
In comparing two algorithms with same starting cash and different cash usage (or visa-versa or both) what you'll need to do is neutralize risk for an apples-to-apples comparison, otherwise returns are in different ball fields.
To start to understand how it works, I go at it from this angle: An algo from Jan 3 this year buying 1 share of SPY every day for a month will have the following returns with different values of starting capital, even though they use the same amount of cash in this case. No shorting, so cash is the only risked value here.
Starting Cash Returns
All have the same PnL ($30) even though returns are apples to oranges.
Returns are pegged only to starting capital no matter how much was used, I gather that is one of the industry's standard methods.
There's a tool that neutralizes both starting capital and cash, measuring PvR (Profit vs Risk) by keeping track of the maximum risk and charting the percentage result. It is PnL/MaximumRisk, performance of each required dollar on average. I score alogorithms with its PvR %/day value included in the output, which should also be removing time from the equation (different date ranges). Still not perfect yet the best I know.
In your code, with investment_set = 1 in both, the one using opt_method has a sudden dip into $3M margin near the end that you'll probably want to address, you can use track_orders and set a valid trading day just before, as its start date, to see what's happening there.
Hope that will help.