Lean Algorithmic Trading Engine by QuantConnect (Python, C#)
This report summarizes scanner evidence for QuantConnect/Lean, a C# project with 21,955 GitHub stars. SynthScan examined 858,220 lines of code across 5062 source files, recording 6399 pattern matches distributed across 22 syntactic categories. The legacy adjusted pattern signal is 9.1 (Moderate pattern signal); it is not an authorship estimate.
Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.
Use each vector to guide manual verification of the underlying findings.
Can maintainers explain intent, assumptions, and trade-offs? 5489 finding(s).
Are imports declared and package/API names verified? 656 finding(s).
Are wrappers, guards, and repeated structures necessary? 467 finding(s).
Which changes need focused human review? 6399 finding(s).
This chart tracks the legacy adjusted pattern score across scan runs. Changes can reflect source changes, scan coverage, or detector/scoring versions; they do not measure AI adoption or prove that a team refactored code. Compare runs only when their scoring versions are compatible. The dashed line tracks the raw pattern-hit count.
Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.
This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.
The scanner identified 6399 distinct pattern matches across 22 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.
Reading the findings table: The Severity column indicates the configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | Research/QuantBook.cs | 341 | }; | COMMENT |
| LOW | Research/QuantBook.cs | 361 | COMMENT | |
| LOW | Research/QuantBook.cs | 461 | // the symbol is a contract | COMMENT |
| LOW | Research/QuantBook.cs | 521 | } | COMMENT |
| LOW | Research/QuantBook.cs | 541 | /// Gets the historical data of an indicator for the specified symbol. The exact number of bars will be returned | COMMENT |
| LOW | Research/QuantBook.cs | 561 | /// <param name="periods">The number of bars to request</param> | COMMENT |
| LOW | Research/QuantBook.cs | 621 | COMMENT | |
| LOW | Research/QuantBook.cs | 641 | /// The symbol must exist in the Securities collection. | COMMENT |
| LOW | Research/QuantBook.cs | 661 | /// <param name="indicator">Indicator</param> | COMMENT |
| LOW | Research/QuantBook.cs | 681 | /// <param name="start">The start time in the algorithm's time zone</param> | COMMENT |
| LOW | Research/QuantBook.cs | 741 | /// </summary> | COMMENT |
| LOW | Research/start.py | 1 | # QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals. | COMMENT |
| LOW | …erDataProvider/DownloaderDataProviderArgumentParser.cs | 41 | /// <summary> | COMMENT |
| LOW | DownloaderDataProvider/Program.cs | 41 | /// </summary> | COMMENT |
| LOW | DownloaderDataProvider/Program.cs | 201 | } | COMMENT |
| LOW | DownloaderDataProvider/Models/DataDownloadConfig.cs | 41 | COMMENT | |
| LOW | DownloaderDataProvider/Models/BaseDataDownloadConfig.cs | 41 | /// <summary> | COMMENT |
| LOW | Configuration/Config.cs | 201 | /// Get the int value of a config string. | COMMENT |
| LOW | Configuration/Config.cs | 301 | /// <summary> | COMMENT |
| LOW | …Framework/Execution/StandardDeviationExecutionModel.cs | 41 | /// Gets or sets the maximum order value in units of the account currency. | COMMENT |
| LOW | …Framework/Execution/StandardDeviationExecutionModel.cs | 181 | { | COMMENT |
| LOW | …Framework/Execution/StandardDeviationExecutionModel.py | 1 | # QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals. | COMMENT |
| LOW | …/Execution/VolumeWeightedAveragePriceExecutionModel.cs | 41 | /// </summary> | COMMENT |
| LOW | Algorithm.Framework/Execution/SpreadExecutionModel.py | 1 | # QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals. | COMMENT |
| LOW | …/Execution/VolumeWeightedAveragePriceExecutionModel.py | 1 | # QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals. | COMMENT |
| LOW | …work/Portfolio/MaximumSharpeRatioPortfolioOptimizer.py | 1 | # QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals. | COMMENT |
| LOW | …k/Portfolio/MeanReversionPortfolioConstructionModel.cs | 81 | /// </summary> | COMMENT |
| LOW | …/MeanVarianceOptimizationPortfolioConstructionModel.cs | 41 | private readonly IPortfolioOptimizer _optimizer; | COMMENT |
| LOW | …/MeanVarianceOptimizationPortfolioConstructionModel.cs | 101 | Resolution resolution = Resolution.Daily, | COMMENT |
| LOW | …/MeanVarianceOptimizationPortfolioConstructionModel.cs | 141 | else | COMMENT |
| LOW | …work/Portfolio/MaximumSharpeRatioPortfolioOptimizer.cs | 21 | COMMENT | |
| LOW | …k/Portfolio/MeanReversionPortfolioConstructionModel.py | 1 | # QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals. | COMMENT |
| LOW | …/MeanVarianceOptimizationPortfolioConstructionModel.py | 1 | # QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals. | COMMENT |
| LOW | …hm.Framework/Portfolio/RiskParityPortfolioOptimizer.py | 1 | # QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals. | COMMENT |
| LOW | …amework/Portfolio/MinimumVariancePortfolioOptimizer.py | 1 | # QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals. | COMMENT |
| LOW | …work/Portfolio/RiskParityPortfolioConstructionModel.py | 1 | # QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals. | COMMENT |
| LOW | …Framework/Portfolio/PortfolioOptimizerPythonWrapper.cs | 21 | { | COMMENT |
| LOW | …/Portfolio/EqualWeightingPortfolioConstructionModel.py | 1 | # QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals. | COMMENT |
| LOW | …Portfolio/SectorWeightingPortfolioConstructionModel.cs | 41 | /// <summary> | COMMENT |
| LOW | …Portfolio/SectorWeightingPortfolioConstructionModel.cs | 61 | COMMENT | |
| LOW | …ortfolio/InsightWeightingPortfolioConstructionModel.cs | 21 | using QuantConnect.Scheduling; | COMMENT |
| LOW | …ortfolio/InsightWeightingPortfolioConstructionModel.cs | 41 | /// in UTC</param> | COMMENT |
| LOW | …ortfolio/InsightWeightingPortfolioConstructionModel.cs | 101 | COMMENT | |
| LOW | …lackLittermanOptimizationPortfolioConstructionModel.cs | 101 | /// <summary> | COMMENT |
| LOW | …lackLittermanOptimizationPortfolioConstructionModel.cs | 161 | /// <summary> | COMMENT |
| LOW | …rk/Portfolio/AlphaStreamsPortfolioConstructionModel.cs | 21 | { | COMMENT |
| LOW | …folio/AccumulativeInsightPortfolioConstructionModel.py | 1 | # QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals. | COMMENT |
| LOW | …tfolio/ConfidenceWeightedPortfolioConstructionModel.py | 1 | # QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals. | COMMENT |
| LOW | …hm.Framework/Portfolio/RiskParityPortfolioOptimizer.cs | 41 | } | COMMENT |
| LOW | …hm.Framework/Portfolio/RiskParityPortfolioOptimizer.cs | 61 | var solution = RiskParityNewtonMethodOptimization(size, covariance, expectedReturns); | COMMENT |
| LOW | …rtfolio/UnconstrainedMeanVariancePortfolioOptimizer.py | 1 | # QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals. | COMMENT |
| LOW | …amework/Portfolio/MinimumVariancePortfolioOptimizer.cs | 21 | COMMENT | |
| LOW | …work/Portfolio/RiskParityPortfolioConstructionModel.cs | 101 | /// </summary> | COMMENT |
| LOW | …work/Portfolio/RiskParityPortfolioConstructionModel.cs | 141 | : this(rebalancingFunc != null ? (Func<DateTime, DateTime?>)(timeUtc => rebalancingFunc(timeUtc)) : null, | COMMENT |
| LOW | …Portfolio/SectorWeightingPortfolioConstructionModel.py | 1 | # QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals. | COMMENT |
| LOW | …/Portfolio/EqualWeightingPortfolioConstructionModel.cs | 21 | using QuantConnect.Scheduling; | COMMENT |
| LOW | …/Portfolio/EqualWeightingPortfolioConstructionModel.cs | 61 | /// <summary> | COMMENT |
| LOW | …ortfolio/InsightWeightingPortfolioConstructionModel.py | 1 | # QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals. | COMMENT |
| LOW | …folio/AccumulativeInsightPortfolioConstructionModel.cs | 21 | using QuantConnect.Scheduling; | COMMENT |
| LOW | …folio/AccumulativeInsightPortfolioConstructionModel.cs | 41 | COMMENT | |
| 4882 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | …Framework/Execution/StandardDeviationExecutionModel.py | 0 | event fired each time the we add/remove securities from the data feed. args: algorithm: the algorithm instance that expe | STRING |
| HIGH | …/Execution/VolumeWeightedAveragePriceExecutionModel.py | 0 | event fired each time the we add/remove securities from the data feed. args: algorithm: the algorithm instance that expe | STRING |
| HIGH | …k/Portfolio/MeanReversionPortfolioConstructionModel.py | 0 | event fired each time the we add/remove securities from the data feed. args: algorithm: the algorithm instance that expe | STRING |
| HIGH | …/MeanVarianceOptimizationPortfolioConstructionModel.py | 0 | event fired each time the we add/remove securities from the data feed. args: algorithm: the algorithm instance that expe | STRING |
| HIGH | …work/Portfolio/RiskParityPortfolioConstructionModel.py | 0 | event fired each time the we add/remove securities from the data feed. args: algorithm: the algorithm instance that expe | STRING |
| HIGH | …Portfolio/SectorWeightingPortfolioConstructionModel.py | 0 | event fired each time the we add/remove securities from the data feed. args: algorithm: the algorithm instance that expe | STRING |
| HIGH | …lackLittermanOptimizationPortfolioConstructionModel.py | 0 | event fired each time the we add/remove securities from the data feed. args: algorithm: the algorithm instance that expe | STRING |
| HIGH | …orithm.Framework/Alphas/HistoricalReturnsAlphaModel.py | 0 | event fired each time the we add/remove securities from the data feed. args: algorithm: the algorithm instance that expe | STRING |
| HIGH | Algorithm.Framework/Alphas/EmaCrossAlphaModel.py | 0 | event fired each time the we add/remove securities from the data feed. args: algorithm: the algorithm instance that expe | STRING |
| HIGH | Algorithm.Framework/Alphas/ConstantAlphaModel.py | 0 | event fired each time the we add/remove securities from the data feed. args: algorithm: the algorithm instance that expe | STRING |
| HIGH | …ework/Risk/MaximumSectorExposureRiskManagementModel.py | 0 | event fired each time the we add/remove securities from the data feed. args: algorithm: the algorithm instance that expe | STRING |
| HIGH | ….Python/Alphas/GasAndCrudeOilEnergyCorrelationAlpha.py | 0 | event fired each time the we add/remove securities from the data feed. args: algorithm: the algorithm instance that expe | STRING |
| HIGH | …ork/Alphas/PearsonCorrelationPairsTradingAlphaModel.py | 0 | event fired each time the we add/remove securities from the data feed. args: algorithm: the algorithm instance that expe | STRING |
| HIGH | …gorithm.Framework/Alphas/BasePairsTradingAlphaModel.py | 0 | event fired each time the we add/remove securities from the data feed. args: algorithm: the algorithm instance that expe | STRING |
| HIGH | …/MeanVarianceOptimizationPortfolioConstructionModel.py | 0 | contains data specific to a symbol required by this model | STRING |
| HIGH | …work/Portfolio/RiskParityPortfolioConstructionModel.py | 0 | contains data specific to a symbol required by this model | STRING |
| HIGH | …lackLittermanOptimizationPortfolioConstructionModel.py | 0 | contains data specific to a symbol required by this model | STRING |
| HIGH | …orithm.Framework/Alphas/HistoricalReturnsAlphaModel.py | 0 | contains data specific to a symbol required by this model | STRING |
| HIGH | Algorithm.Framework/Alphas/EmaCrossAlphaModel.py | 0 | contains data specific to a symbol required by this model | STRING |
| HIGH | Algorithm.Framework/Alphas/RsiAlphaModel.py | 0 | contains data specific to a symbol required by this model | STRING |
| HIGH | Algorithm.Python/Alphas/GreenblattMagicFormulaAlpha.py | 0 | contains data specific to a symbol required by this model | STRING |
| HIGH | Algorithm.Python/Alphas/VIXDualThrustAlpha.py | 0 | contains data specific to a symbol required by this model | STRING |
| HIGH | ….Python/Alphas/GasAndCrudeOilEnergyCorrelationAlpha.py | 0 | contains data specific to a symbol required by this model | STRING |
| HIGH | …/Portfolio/EqualWeightingPortfolioConstructionModel.py | 0 | initialize a new instance of insightweightingportfolioconstructionmodel args: rebalance: rebalancing parameter. if it is | STRING |
| HIGH | …folio/AccumulativeInsightPortfolioConstructionModel.py | 0 | initialize a new instance of insightweightingportfolioconstructionmodel args: rebalance: rebalancing parameter. if it is | STRING |
| HIGH | …tfolio/ConfidenceWeightedPortfolioConstructionModel.py | 0 | initialize a new instance of insightweightingportfolioconstructionmodel args: rebalance: rebalancing parameter. if it is | STRING |
| HIGH | …Portfolio/SectorWeightingPortfolioConstructionModel.py | 0 | initialize a new instance of insightweightingportfolioconstructionmodel args: rebalance: rebalancing parameter. if it is | STRING |
| HIGH | …ortfolio/InsightWeightingPortfolioConstructionModel.py | 0 | initialize a new instance of insightweightingportfolioconstructionmodel args: rebalance: rebalancing parameter. if it is | STRING |
| HIGH | …/Portfolio/EqualWeightingPortfolioConstructionModel.py | 0 | will determine the target percent for each insight args: active_insights: the active insights to generate a target for | STRING |
| HIGH | …folio/AccumulativeInsightPortfolioConstructionModel.py | 0 | will determine the target percent for each insight args: active_insights: the active insights to generate a target for | STRING |
| HIGH | …Portfolio/SectorWeightingPortfolioConstructionModel.py | 0 | will determine the target percent for each insight args: active_insights: the active insights to generate a target for | STRING |
| HIGH | …ortfolio/InsightWeightingPortfolioConstructionModel.py | 0 | will determine the target percent for each insight args: active_insights: the active insights to generate a target for | STRING |
| HIGH | …tfolio/ConfidenceWeightedPortfolioConstructionModel.py | 0 | method that will determine if the portfolio construction model should create a target for this insight args: insight: th | STRING |
| HIGH | …Portfolio/SectorWeightingPortfolioConstructionModel.py | 0 | method that will determine if the portfolio construction model should create a target for this insight args: insight: th | STRING |
| HIGH | …ortfolio/InsightWeightingPortfolioConstructionModel.py | 0 | method that will determine if the portfolio construction model should create a target for this insight args: insight: th | STRING |
| HIGH | …orithm.Framework/Alphas/HistoricalReturnsAlphaModel.py | 0 | updates this alpha model with the latest data from the algorithm. this is called each time the algorithm receives data f | STRING |
| HIGH | …gorithm.Framework/Alphas/BasePairsTradingAlphaModel.py | 0 | updates this alpha model with the latest data from the algorithm. this is called each time the algorithm receives data f | STRING |
| HIGH | Algorithm.Framework/Alphas/EmaCrossAlphaModel.py | 0 | updates this alpha model with the latest data from the algorithm. this is called each time the algorithm receives data f | STRING |
| HIGH | Algorithm.Framework/Alphas/RsiAlphaModel.py | 0 | updates this alpha model with the latest data from the algorithm. this is called each time the algorithm receives data f | STRING |
| HIGH | …phas/ContingentClaimsAnalysisDefaultPredictionAlpha.py | 0 | updates this alpha model with the latest data from the algorithm. this is called each time the algorithm receives data f | STRING |
| HIGH | …amework/Selection/FundamentalUniverseSelectionModel.py | 0 | creates a new fundamental universe using this class's selection functions args: algorithm: the algorithm instance to cre | STRING |
| HIGH | …hm.Framework/Selection/OptionUniverseSelectionModel.py | 0 | creates a new fundamental universe using this class's selection functions args: algorithm: the algorithm instance to cre | STRING |
| HIGH | …hm.Framework/Selection/FutureUniverseSelectionModel.py | 0 | creates a new fundamental universe using this class's selection functions args: algorithm: the algorithm instance to cre | STRING |
| HIGH | …hm.Framework/Selection/OptionUniverseSelectionModel.py | 0 | gets the next time the framework should invoke the `createuniverses` method to refresh the set of universes. | STRING |
| HIGH | …hm.Framework/Selection/FutureUniverseSelectionModel.py | 0 | gets the next time the framework should invoke the `createuniverses` method to refresh the set of universes. | STRING |
| HIGH | Algorithm/Selection/UniverseSelectionModel.py | 0 | gets the next time the framework should invoke the `createuniverses` method to refresh the set of universes. | STRING |
| HIGH | …ithm.Framework/Risk/MaximumDrawdownPercentPortfolio.py | 0 | manages the algorithm's risk at each time step args: algorithm: the algorithm instance targets: the current portfolio ta | STRING |
| HIGH | …ithm.Framework/Risk/TrailingStopRiskManagementModel.py | 0 | manages the algorithm's risk at each time step args: algorithm: the algorithm instance targets: the current portfolio ta | STRING |
| HIGH | …work/Risk/MaximumUnrealizedProfitPercentPerSecurity.py | 0 | manages the algorithm's risk at each time step args: algorithm: the algorithm instance targets: the current portfolio ta | STRING |
| HIGH | …hm.Framework/Risk/MaximumDrawdownPercentPerSecurity.py | 0 | manages the algorithm's risk at each time step args: algorithm: the algorithm instance targets: the current portfolio ta | STRING |
| HIGH | Algorithm/Risk/CompositeRiskManagementModel.py | 0 | manages the algorithm's risk at each time step args: algorithm: the algorithm instance targets: the current portfolio ta | STRING |
| HIGH | …hm.Python/NumeraiSignalExportDemonstrationAlgorithm.py | 0 | initialize the date and add all equity symbols present in list _symbols | STRING |
| HIGH | …lective2PortfolioSignalExportDemonstrationAlgorithm.py | 0 | initialize the date and add all equity symbols present in list _symbols | STRING |
| HIGH | …ython/Collective2SignalExportDemonstrationAlgorithm.py | 0 | initialize the date and add all equity symbols present in list _symbols | STRING |
| HIGH | …thm.Python/CustomSignalExportDemonstrationAlgorithm.py | 0 | initialize the date and add all equity symbols present in list _symbols | STRING |
| HIGH | Algorithm.Python/ConstituentsQC500GeneratorAlgorithm.py | 0 | initialise the data and resolution required, as well as the cash and start-end dates for your algorithm. all algorithms | STRING |
| HIGH | Algorithm.Python/UpdateOrderRegressionAlgorithm.py | 0 | initialise the data and resolution required, as well as the cash and start-end dates for your algorithm. all algorithms | STRING |
| HIGH | …on/AddOptionContractFromUniverseRegressionAlgorithm.py | 0 | initialise the data and resolution required, as well as the cash and start-end dates for your algorithm. all algorithms | STRING |
| HIGH | Algorithm.Python/BasicTemplateCfdAlgorithm.py | 0 | initialise the data and resolution required, as well as the cash and start-end dates for your algorithm. all algorithms | STRING |
| HIGH | …on/CoarseFineOptionUniverseChainRegressionAlgorithm.py | 0 | initialise the data and resolution required, as well as the cash and start-end dates for your algorithm. all algorithms | STRING |
| 162 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | …k/Portfolio/MeanReversionPortfolioConstructionModel.py | 73 | # If we have no insights or non-ready just return an empty target list | COMMENT |
| LOW | …/MeanVarianceOptimizationPortfolioConstructionModel.py | 85 | # If we have no insights just return an empty target list | COMMENT |
| LOW | …work/Portfolio/RiskParityPortfolioConstructionModel.py | 74 | # If we have no insights just return an empty target list | COMMENT |
| MEDIUM | Algorithm.CSharp/MarginCallEventsAlgorithm.cs | 45 | // cranking up the leverage increases the odds of a margin call when the security falls in value | COMMENT |
| MEDIUM | …orithm.CSharp/FractionalQuantityRegressionAlgorithm.cs | 47 | // Since this test algorithm uses leverage we need to set a buying power model with margin. | COMMENT |
| MEDIUM | …Sharp/SetHoldingsMultipleTargetsRegressionAlgorithm.cs | 41 | // use leverage 1 so we test the margin impact ordering | COMMENT |
| MEDIUM⚡ | …ithm.CSharp/NoMarginCallExpectedRegressionAlgorithm.cs | 54 | // market leverage 10 minutes before market closes. | COMMENT |
| MEDIUM⚡ | …ithm.CSharp/NoMarginCallExpectedRegressionAlgorithm.cs | 57 | // before market close we reduce our position to closed market leverage | COMMENT |
| MEDIUM⚡ | …ithm.CSharp/NoMarginCallExpectedRegressionAlgorithm.cs | 66 | // at market open we increase our position to open market leverage | COMMENT |
| MEDIUM | …/CryptoFutureLeverageBasedMarginRegressionAlgorithm.cs | 26 | /// changing leverage on a crypto future | COMMENT |
| MEDIUM | …/CryptoFutureLeverageBasedMarginRegressionAlgorithm.cs | 57 | SetHoldings(_cryptoFuture.Symbol, 10); // Buy all we can with our margin (leverage is 10) | CODE |
| MEDIUM | …/CryptoFutureLeverageBasedMarginRegressionAlgorithm.cs | 87 | SetHoldings(_cryptoFuture.Symbol, 20); // Buy all we can with our margin (new leverage is 20) | CODE |
| MEDIUM | Algorithm.CSharp/CustomSecurityInitializerAlgorithm.cs | 72 | /// so we can also take advantage of the default model/leverage setting | COMMENT |
| MEDIUM | …hm.CSharp/MarginCallClosedMarketRegressionAlgorithm.cs | 76 | // we should reduce our position by the same relation between the open and closed market leverage | COMMENT |
| MEDIUM | Algorithm.CSharp/OpeningBreakoutAlgorithm.cs | 121 | // leverage tradier $1 traders | COMMENT |
| MEDIUM | Algorithm.CSharp/OpeningBreakoutAlgorithm.cs | 130 | // Set our max leverage | COMMENT |
| MEDIUM | Algorithm.CSharp/OpeningBreakoutAlgorithm.cs | 304 | // min out at 1x leverage | COMMENT |
| MEDIUM | …/ETFConstituentUniverseFrameworkRegressionAlgorithm.cs | 198 | /// to the leverage of the ETF (1x, 2x, 3x, etc.) | COMMENT |
| MEDIUM | …p/Alphas/TripleLeveragedETFPairVolatilityDecayAlpha.cs | 29 | /// Leveraged ETFs (LETF) promise a fixed leverage ratio with respect to an underlying asset or an index. | COMMENT |
| MEDIUM | …rithmFactory/Python/Wrappers/AlgorithmPythonWrapper.cs | 598 | /// <param name="leverage">leverage for this security</param> | COMMENT |
| MEDIUM | …rithmFactory/Python/Wrappers/AlgorithmPythonWrapper.cs | 613 | /// <param name="leverage">leverage for this security</param> | COMMENT |
| MEDIUM | …rithmFactory/Python/Wrappers/AlgorithmPythonWrapper.cs | 630 | /// <param name="leverage">The requested leverage for this equity. Default is set by <see cref="SecurityInitiali | COMMENT |
| MEDIUM | …rithmFactory/Python/Wrappers/AlgorithmPythonWrapper.cs | 643 | /// <param name="leverage">The requested leverage for this equity. Default is set by <see cref="SecurityInitiali | COMMENT |
| MEDIUM | Indicators/ConnorsRelativeStrengthIndex.cs | 25 | /// This index is designed to provide a more robust measure of market strength | COMMENT |
| LOW | Tests/Python/PythonPackagesTests.cs | 993 | # specifying a single input parameter. In this example, we just pass the random | COMMENT |
| MEDIUM | Tests/Algorithm/AlgorithmSetHoldingsTests.cs | 141 | //Console.WriteLine("Leverage: " + leverage); | COMMENT |
| MEDIUM | …rities/PatternDayTradingMarginBuyingPowerModelTests.cs | 51 | // No parameters initialization, used default PDT 4x leverage open market and 2x leverage otherwise | COMMENT |
| MEDIUM | Tests/Common/Securities/SecurityMarginModelTests.cs | 65 | // Initial and maintenance margin = (1000 * 20) / leverage = X | COMMENT |
| MEDIUM | Tests/Common/Securities/SecurityMarginModelTests.cs | 88 | // Initial and maintenance margin = (1000 * 20) / leverage = X | COMMENT |
| MEDIUM | …sts/Common/Securities/SecurityPortfolioManagerTests.cs | 356 | // now the stock doubles, leverage is 1 we shouldn't have more margin remaining | COMMENT |
| MEDIUM | …sts/Common/Securities/SecurityPortfolioManagerTests.cs | 372 | // now the stock plummets, leverage is 1 we shouldn't have margin remaining | COMMENT |
| MEDIUM | …sts/Common/Securities/SecurityPortfolioManagerTests.cs | 382 | // this would not cause a margin call due to leverage = 1 | COMMENT |
| MEDIUM | …Common/Securities/FutureMarginBuyingPowerModelTests.cs | 289 | // we have a massive loss because of futures leverage | COMMENT |
| MEDIUM | …Common/Securities/FutureMarginBuyingPowerModelTests.cs | 320 | // we have a massive win because of futures leverage | COMMENT |
| MEDIUM | …Common/Securities/OptionMarginBuyingPowerModelTests.cs | 45 | // we test that options dont have leverage (100%) and it cannot be changed | COMMENT |
| MEDIUM⚡ | Tests/Common/Securities/MarginCallModelTests.cs | 202 | // leverage is 1 we shouldn't have more margin remaining | COMMENT |
| MEDIUM⚡ | Tests/Common/Securities/MarginCallModelTests.cs | 212 | // now the stock plummets, leverage is 1 we shouldn't have more margin remaining | COMMENT |
| MEDIUM⚡ | Tests/Common/Securities/MarginCallModelTests.cs | 222 | // this would not cause a margin call due to leverage = 1 | COMMENT |
| MEDIUM⚡ | Tests/Common/Securities/MarginCallModelTests.cs | 228 | // now change the leverage to test margin call warning and margin call logic | COMMENT |
| MEDIUM⚡ | Tests/Common/Securities/MarginCallModelTests.cs | 230 | // simulate a loan - when we fill using leverage it will set a negative cash amount | COMMENT |
| MEDIUM | …ecurities/CryptoFuture/CryptoFutureMarginModelTests.cs | 57 | // ((quantity * contract mutiplier * price) / leverage) * conversion rate (BTC -> USD) | COMMENT |
| MEDIUM | …ecurities/CryptoFuture/CryptoFutureMarginModelTests.cs | 62 | // ((quantity * contract mutiplier * price) / leverage) * conversion rate (USDT ~= USD) | COMMENT |
| MEDIUM | Tests/Engine/Setup/BrokerageSetupHandlerTests.cs | 233 | // Assert Leverage setting persisted for non options or futures (Blocked from setting leverage in Securi | COMMENT |
| MEDIUM | Algorithm/QCAlgorithm.Trading.cs | 1423 | /// if you have 2x leverage and request 100% holdings, it will utilize half of the | COMMENT |
| MEDIUM | Algorithm/QCAlgorithm.Python.cs | 107 | /// <param name="leverage">Custom leverage per security</param> | COMMENT |
| MEDIUM | Algorithm/QCAlgorithm.Python.cs | 127 | /// <param name="leverage">Custom leverage per security</param> | COMMENT |
| MEDIUM | Algorithm/QCAlgorithm.Python.cs | 151 | /// <param name="leverage">Custom leverage per security</param> | COMMENT |
| MEDIUM | Algorithm/QCAlgorithm.Python.cs | 190 | /// <param name="leverage">Custom leverage per security</param> | COMMENT |
| MEDIUM | Algorithm/QCAlgorithm.Python.cs | 216 | /// <param name="leverage">Custom leverage per security</param> | COMMENT |
| MEDIUM | Algorithm/QCAlgorithm.Python.cs | 261 | /// <param name="leverage">Custom leverage per security</param> | COMMENT |
| MEDIUM | Algorithm/QCAlgorithm.cs | 1434 | // save the existing leverage specified in AddSecurity, | COMMENT |
| MEDIUM | Algorithm/QCAlgorithm.cs | 1441 | // restore the saved leverage | COMMENT |
| MEDIUM | Algorithm/QCAlgorithm.cs | 1959 | /// <param name="leverage">Custom leverage per security</param> | COMMENT |
| MEDIUM | Algorithm/QCAlgorithm.cs | 1963 | /// <remarks> AddSecurity(SecurityType securityType, Symbol symbol, Resolution resolution, bool fillForward, dec | COMMENT |
| MEDIUM | Algorithm/QCAlgorithm.cs | 1979 | /// <param name="leverage">leverage for this security</param> | COMMENT |
| MEDIUM | Algorithm/QCAlgorithm.cs | 2025 | /// <param name="leverage">leverage for this security</param> | COMMENT |
| MEDIUM | Algorithm/QCAlgorithm.cs | 2216 | /// <param name="leverage">The requested leverage for this equity. Default is set by <see cref="SecurityInitiali | COMMENT |
| MEDIUM | Algorithm/QCAlgorithm.cs | 2234 | /// <param name="leverage">The requested leverage for this equity. Default is set by <see cref="SecurityInitiali | COMMENT |
| MEDIUM | Algorithm/QCAlgorithm.cs | 2254 | /// <param name="leverage">The requested leverage for the </param> | COMMENT |
| MEDIUM | Algorithm/QCAlgorithm.cs | 2273 | /// <param name="leverage">The requested leverage for the </param> | COMMENT |
| 167 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | Research/start.py | 30 | CODE | |
| LOW | …Framework/Execution/StandardDeviationExecutionModel.py | 14 | CODE | |
| LOW | Algorithm.Framework/Execution/SpreadExecutionModel.py | 14 | CODE | |
| LOW | …/Execution/VolumeWeightedAveragePriceExecutionModel.py | 14 | CODE | |
| LOW | …work/Portfolio/MaximumSharpeRatioPortfolioOptimizer.py | 14 | CODE | |
| LOW | …k/Portfolio/MeanReversionPortfolioConstructionModel.py | 14 | CODE | |
| LOW | …/MeanVarianceOptimizationPortfolioConstructionModel.py | 14 | CODE | |
| LOW | …hm.Framework/Portfolio/RiskParityPortfolioOptimizer.py | 14 | CODE | |
| LOW | …hm.Framework/Portfolio/RiskParityPortfolioOptimizer.py | 15 | CODE | |
| LOW | …amework/Portfolio/MinimumVariancePortfolioOptimizer.py | 14 | CODE | |
| LOW | …work/Portfolio/RiskParityPortfolioConstructionModel.py | 14 | CODE | |
| LOW | …/Portfolio/EqualWeightingPortfolioConstructionModel.py | 14 | CODE | |
| LOW | …folio/AccumulativeInsightPortfolioConstructionModel.py | 14 | CODE | |
| LOW | …tfolio/ConfidenceWeightedPortfolioConstructionModel.py | 14 | CODE | |
| LOW | …Portfolio/SectorWeightingPortfolioConstructionModel.py | 14 | CODE | |
| LOW | …ortfolio/InsightWeightingPortfolioConstructionModel.py | 14 | CODE | |
| LOW | …lackLittermanOptimizationPortfolioConstructionModel.py | 14 | CODE | |
| LOW | …lackLittermanOptimizationPortfolioConstructionModel.py | 17 | CODE | |
| LOW | …orithm.Framework/Alphas/HistoricalReturnsAlphaModel.py | 14 | CODE | |
| LOW | …ork/Alphas/PearsonCorrelationPairsTradingAlphaModel.py | 14 | CODE | |
| LOW | Algorithm.Framework/Alphas/MacdAlphaModel.py | 14 | CODE | |
| LOW | …gorithm.Framework/Alphas/BasePairsTradingAlphaModel.py | 14 | CODE | |
| LOW | Algorithm.Framework/Alphas/EmaCrossAlphaModel.py | 14 | CODE | |
| LOW | Algorithm.Framework/Alphas/RsiAlphaModel.py | 14 | CODE | |
| LOW | Algorithm.Framework/Alphas/RsiAlphaModel.py | 15 | CODE | |
| LOW | Algorithm.Framework/Alphas/ConstantAlphaModel.py | 14 | CODE | |
| LOW | …ork/Selection/ETFConstituentsUniverseSelectionModel.py | 14 | CODE | |
| LOW | …thm.Framework/Selection/QC500UniverseSelectionModel.py | 14 | CODE | |
| LOW | …amework/Selection/FundamentalUniverseSelectionModel.py | 14 | CODE | |
| LOW | …hm.Framework/Selection/OptionUniverseSelectionModel.py | 14 | CODE | |
| LOW | ….Framework/Selection/EmaCrossUniverseSelectionModel.py | 14 | CODE | |
| LOW | …hm.Framework/Selection/FutureUniverseSelectionModel.py | 14 | CODE | |
| LOW | …ework/Risk/MaximumSectorExposureRiskManagementModel.py | 14 | CODE | |
| LOW | …ithm.Framework/Risk/MaximumDrawdownPercentPortfolio.py | 14 | CODE | |
| LOW | …ithm.Framework/Risk/TrailingStopRiskManagementModel.py | 14 | CODE | |
| LOW | …work/Risk/MaximumUnrealizedProfitPercentPerSecurity.py | 14 | CODE | |
| LOW | …hm.Framework/Risk/MaximumDrawdownPercentPerSecurity.py | 14 | CODE | |
| LOW | …/Research/RegressionScripts/Test_QuantBookIndicator.py | 14 | CODE | |
| LOW | …ts/Research/RegressionScripts/Test_QuantBookHistory.py | 14 | CODE | |
| LOW | …ts/Research/RegressionScripts/Test_QuantBookHistory.py | 16 | CODE | |
| LOW | Tests/Research/RegressionScripts/custom_data.py | 14 | CODE | |
| LOW | Tests/TestData/generate_reference_data_from_talipp.py | 4 | CODE | |
| LOW | Tests/Python/PandasTests/PandasIndexingTests.py | 14 | CODE | |
| LOW | Tests/Python/PandasTests/PandasIndexingTests.py | 15 | CODE | |
| LOW | Tests/Python/PandasTests/PandasIndexingTests.py | 16 | CODE | |
| LOW | Tests/Python/PandasTests/PandasMapperTests.py | 48 | CODE | |
| LOW | Tests/Python/PandasTests/PandasMapperTests.py | 54 | CODE | |
| LOW | …ts/RegressionAlgorithms/Test_AlgorithmPythonWrapper.py | 14 | CODE | |
| LOW | …egressionAlgorithms/Test_PythonExceptionInterpreter.py | 14 | CODE | |
| LOW | …egressionAlgorithms/Test_PythonExceptionInterpreter.py | 59 | CODE | |
| LOW | Tests/RegressionAlgorithms/Test_MethodOverload.py | 14 | CODE | |
| LOW | Tests/RegressionAlgorithms/Test_CustomDataAlgorithm.py | 14 | CODE | |
| LOW | Tests/RegressionAlgorithms/Test_CustomDataAlgorithm.py | 16 | CODE | |
| LOW | Algorithm/Execution/ImmediateExecutionModel.py | 14 | CODE | |
| LOW | Algorithm/Execution/NullExecutionModel.py | 14 | CODE | |
| LOW | Algorithm/Portfolio/NullPortfolioConstructionModel.py | 14 | CODE | |
| LOW | Algorithm/Alphas/NullAlphaModel.py | 14 | CODE | |
| LOW | Algorithm/Selection/UniverseSelectionModel.py | 14 | CODE | |
| LOW | Algorithm/Selection/ManualUniverseSelectionModel.py | 14 | CODE | |
| LOW | Algorithm/Risk/NullRiskManagementModel.py | 14 | CODE | |
| 577 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | …/Execution/VolumeWeightedAveragePriceExecutionModel.py | 146 | def get_volume_and_average_price(self, input): | CODE |
| LOW | …/MeanVarianceOptimizationPortfolioConstructionModel.py | 65 | def should_create_target_for_insight(self, insight): | CODE |
| LOW | …/MeanVarianceOptimizationPortfolioConstructionModel.py | 148 | def on_rate_of_change_updated(self, roc, value): | CODE |
| LOW | …work/Portfolio/RiskParityPortfolioConstructionModel.py | 139 | def on_rate_of_change_updated(self, roc, value): | CODE |
| LOW | …tfolio/ConfidenceWeightedPortfolioConstructionModel.py | 38 | def should_create_target_for_insight(self, insight): | CODE |
| LOW | …Portfolio/SectorWeightingPortfolioConstructionModel.py | 37 | def should_create_target_for_insight(self, insight): | CODE |
| LOW | …ortfolio/InsightWeightingPortfolioConstructionModel.py | 38 | def should_create_target_for_insight(self, insight): | CODE |
| LOW | …lackLittermanOptimizationPortfolioConstructionModel.py | 80 | def should_create_target_for_insight(self, insight): | CODE |
| LOW | …lackLittermanOptimizationPortfolioConstructionModel.py | 172 | def apply_blacklitterman_master_formula(self, Pi, Sigma, P, Q): | CODE |
| LOW | …lackLittermanOptimizationPortfolioConstructionModel.py | 288 | def on_rate_of_change_updated(self, roc, value): | CODE |
| LOW | …gorithm.Framework/Alphas/BasePairsTradingAlphaModel.py | 132 | def create_identity_indicator(symbol: Symbol): | CODE |
| LOW | …amework/Selection/FundamentalUniverseSelectionModel.py | 61 | def create_coarse_fundamental_universe(self, algorithm: QCAlgorithm) -> Universe: | CODE |
| LOW | …hm.Framework/Selection/OptionUniverseSelectionModel.py | 34 | def get_next_refresh_time_utc(self): | CODE |
| LOW | …hm.Framework/Selection/FutureUniverseSelectionModel.py | 35 | def get_next_refresh_time_utc(self): | CODE |
| LOW | …ithm.Framework/Risk/MaximumDrawdownPercentPortfolio.py | 63 | def get_total_drawdown_percent(self, current_value): | CODE |
| LOW⚡ | …/Research/RegressionScripts/Test_QuantBookIndicator.py | 37 | def test_bollinger_bands_backwards_compatibility(self, symbol, start, end, resolution): | CODE |
| LOW⚡ | …/Research/RegressionScripts/Test_QuantBookIndicator.py | 41 | def test_average_true_range_backwards_compatibility(self, symbol, start, end, resolution): | CODE |
| LOW⚡ | …/Research/RegressionScripts/Test_QuantBookIndicator.py | 45 | def test_on_balance_volume_backwards_compatibility(self, symbol, start, end, resolution): | CODE |
| LOW | Tests/TestData/generate_reference_data_from_talib.py | 24 | def generate_reference_data_for_single_output_indicator( | CODE |
| LOW | Tests/TestData/generate_reference_data_from_talib.py | 36 | def generate_reference_data_for_multi_output_indicator( | CODE |
| LOW | Tests/TestData/generate_reference_data_from_talipp.py | 20 | def generate_reference_data_for_siso_indicator( | CODE |
| LOW | Tests/TestData/generate_reference_data_from_talipp.py | 30 | def generate_reference_data_for_miso_indicator( | CODE |
| LOW | Tests/TestData/generate_reference_data_from_talipp.py | 49 | def generate_reference_data_for_simo_indicator( | CODE |
| LOW | Tests/TestData/generate_reference_data_from_talipp.py | 69 | def generate_reference_data_for_mimo_indicator( | CODE |
| LOW | Tests/TestData/generate_reference_data_from_talipp.py | 98 | def generate_reference_data_for_zigzag_indicator( | CODE |
| LOW | Tests/TestData/generate_reference_data_from_tulip.py | 17 | def generate_reference_data_for_siso_indicator( | CODE |
| LOW⚡ | Tests/Python/AlgorithmImportsTests.cs | 38 | def exception_is_the_python_builtin(): | CODE |
| LOW⚡ | Tests/Python/AlgorithmImportsTests.cs | 41 | def except_clause_catches_python_exceptions(): | CODE |
| LOW⚡ | Tests/Python/AlgorithmImportsTests.cs | 49 | def except_clause_catches_clr_exceptions(action): | CODE |
| LOW | Tests/Python/BasePythonWrapperTests.cs | 123 | def set_return_valid_out_param_type(self, value): | CODE |
| LOW | Tests/Python/BasePythonWrapperTests.cs | 157 | def set_return_valid_out_params_count(self, value): | CODE |
| LOW | Tests/Python/BasePythonWrapperTests.cs | 188 | def set_use_valid_return_type(self, value): | CODE |
| LOW | Tests/Python/BasePythonWrapperTests.cs | 219 | def set_use_valid_return_type(self, value): | CODE |
| LOW | Tests/Python/BasePythonWrapperTests.cs | 284 | def set_use_valid_return_type(self, value): | CODE |
| LOW | Tests/Python/BasePythonWrapperTests.cs | 350 | def set_use_valid_return_type(self, value): | CODE |
| LOW | Tests/Python/PandasTests/PandasIndexingTests.py | 27 | def test_indexing_dataframe_with_list(self): | CODE |
| LOW | Tests/Python/PandasTests/PandasIndexingTests.py | 49 | def test_contains_user_mapped_ticker(self): | CODE |
| LOW | Tests/Python/PandasTests/PandasIndexingTests.py | 62 | def test_contains_user_defined_columns_with_spaces(self, column_name): | CODE |
| LOW | Tests/Python/PandasTests/PandasIndexingTests.py | 73 | def test_column_equals_only_matching_string(self): | CODE |
| LOW | Tests/Indicators/OptionBaseIndicatorTests.cs | 422 | def get_option_indicator_base_indicator(symbol: Symbol) -> OptionIndicatorBase: | CODE |
| LOW | Tests/Indicators/RollingWindowTests.cs | 550 | def rolling_window_with_tuple(): | CODE |
| LOW⚡ | Tests/Indicators/RollingWindowTests.cs | 570 | def rolling_window_with_float(): | CODE |
| LOW⚡ | Tests/Indicators/RollingWindowTests.cs | 577 | def rolling_window_with_trade_bar(): | CODE |
| LOW⚡ | Tests/Indicators/RollingWindowTests.cs | 584 | def rolling_window_with_quote_bar(): | CODE |
| LOW⚡ | Tests/Indicators/RollingWindowTests.cs | 591 | def rolling_window_with_custom_data_type(): | CODE |
| LOW | Tests/Indicators/CompositeIndicatorTests.cs | 114 | def create_composite_indicator(left, right, operation): | CODE |
| LOW | Tests/Algorithm/AlgorithmAddSecurityTests.cs | 479 | def add_security_initializers(algorithm): | CODE |
| LOW | Tests/Algorithm/AlgorithmAddSecurityTests.cs | 614 | def add_security_initializers(algorithm): | CODE |
| LOW | Tests/Algorithm/AlgorithmAddSecurityTests.cs | 703 | def add_security_initializers(algorithm): | CODE |
| LOW | Tests/Algorithm/AlgorithmIndicatorsTests.cs | 756 | def create_intraday_vwap_indicator(name): | CODE |
| LOW | …thm/Framework/FrameworkModelsPythonInheritanceTests.cs | 136 | def create_coarse_fundamental_universe(self, algorithm): | CODE |
| LOW | Tests/Common/Securities/SecurityCacheTests.cs | 627 | def get_security_cache_margin_interest_rate(): | CODE |
| LOW | Tests/Common/Securities/SecurityCacheTests.cs | 633 | def get_security_cache_custom_data_type(): | CODE |
| LOW | Tests/Engine/DataFeeds/DataQueueHandlerManagerTests.cs | 214 | private class TestDataHandler : IDataQueueHandler | CODE |
| LOW | Tests/Engine/DataFeeds/DataQueueHandlerManagerTests.cs | 241 | private class ExplodingDataHandler : TestDataHandler | CODE |
| LOW | …egressionAlgorithms/Test_PythonExceptionInterpreter.py | 28 | def attribute_error_quote_bar_volume(self): | CODE |
| LOW | …egressionAlgorithms/Test_PythonExceptionInterpreter.py | 31 | def attribute_error_trade_bar_ask_price(self): | CODE |
| LOW | …egressionAlgorithms/Test_PythonExceptionInterpreter.py | 49 | def unsupported_operand_datetime_date(self): | CODE |
| LOW | …egressionAlgorithms/Test_PythonExceptionInterpreter.py | 52 | def unsupported_operand_date_datetime(self): | CODE |
| LOW | Tests/RegressionAlgorithms/Test_MethodOverload.py | 38 | def call_plot_throw_managed_test(self): | CODE |
| 147 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| CRITICAL | Tests/Algorithm/AlgorithmHistoryTests.cs | 4661 | Assert.That(historyResults, Has.All.Not.Empty.And.All.Count.EqualTo(expectedHistoryCount), | CODE |
| CRITICAL | Tests/Algorithm/AlgorithmAddUniverseTests.cs | 116 | Assert.IsTrue(constituentUniverse.Configuration.Symbol.ID.Symbol.StartsWithInvariant("qc-universe-")); | CODE |
| CRITICAL | …election/ETFConstituentsUniverseSelectionModelTests.cs | 168 | Assert.IsTrue(universe.Configuration.Symbol.ID.Symbol.StartsWithInvariant("qc-universe-")); | CODE |
| CRITICAL | Tests/Common/Util/PythonUtilTests.cs | 138 | at QuantConnect.AlgorithmFactory.Python.Wrappers.AlgorithmPythonWrapper.Initialize() in D:\QuantConnect\MyLean\Lean\A | CODE |
| CRITICAL | Tests/Common/Util/PythonUtilTests.cs | 155 | at QuantConnect.AlgorithmFactory.Python.Wrappers.AlgorithmPythonWrapper.Initialize() in D:\QuantConnect\MyLean\Lean\A | CODE |
| CRITICAL | Tests/Common/Util/PythonUtilTests.cs | 193 | at QuantConnect.AlgorithmFactory.Python.Wrappers.AlgorithmPythonWrapper.OnData(Slice slice) in /home/user/QuantConnec | CODE |
| CRITICAL | Tests/Common/Util/PythonUtilTests.cs | 208 | at QuantConnect.AlgorithmFactory.Python.Wrappers.AlgorithmPythonWrapper.OnData(Slice slice) in D:\QuantConnect\MyLean | CODE |
| CRITICAL | Tests/Common/Util/PythonUtilTests.cs | 225 | at QuantConnect.AlgorithmFactory.Python.Wrappers.AlgorithmPythonWrapper.OnData(Slice slice) in C:\Users\user\QuantCon | CODE |
| CRITICAL | Tests/Common/Data/SubscriptionManagerTests.cs | 176 | var tickers = QuantConnect.Algorithm.CSharp.StressSymbols.StockSymbols.ToList(); | CODE |
| CRITICAL | Tests/Common/Data/SubscriptionManagerTests.cs | 213 | var tickers = QuantConnect.Algorithm.CSharp.StressSymbols.StockSymbols.Take(100).ToList(); | CODE |
| CRITICAL | Tests/Engine/PerformanceBenchmarkAlgorithms.cs | 75 | foreach (var symbol in QuantConnect.Algorithm.CSharp.Benchmarks.Symbols.Equity.All.Take(500)) | CODE |
| CRITICAL | Tests/Engine/PerformanceBenchmarkAlgorithms.cs | 97 | foreach (var symbol in QuantConnect.Algorithm.CSharp.Benchmarks.Symbols.Equity.All.Take(_parameters.Secu | CODE |
| CRITICAL | …andlerTests/ContingentOrdersTransactionHandlerTests.cs | 478 | var bracket = QuantConnect.Tests.Common.Orders.ContingentOrderTests.CreateBracket(); | CODE |
| CRITICAL | Tests/Engine/DataFeeds/FileSystemDataFeedTests.cs | 276 | Assert.IsTrue(universeData.Any(kvp => kvp.Key.Configuration.Symbol.ID.Symbol.Contains("CONTINUOU | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | …/MeanVarianceOptimizationPortfolioConstructionModel.py | 91 | # Create a dictionary keyed by the symbols in the insights with an pandas.series as value to create a data frame | COMMENT |
| MEDIUM | …work/Portfolio/RiskParityPortfolioConstructionModel.py | 80 | # Create a dictionary keyed by the symbols in the insights with an pandas.series as value to create a data frame | COMMENT |
| MEDIUM | …lackLittermanOptimizationPortfolioConstructionModel.py | 91 | # Create a dictionary keyed by the symbols in the insights with an pandas.Series as value to create a data f | COMMENT |
| MEDIUM | …lackLittermanOptimizationPortfolioConstructionModel.py | 182 | # Create the diagonal Sigma matrix of error terms from the expressed views | COMMENT |
| MEDIUM | …rch/RegressionTemplates/BasicTemplateResearchPython.cs | 78 | ", it is a datapoint indicator\", \"# Define the indicator\", \"bb = BollingerBands(30, 2)\", \"\", | CODE |
| MEDIUM | …es/BasicTemplateCustomDataTypeHistoryResearchPython.cs | 68 | "tags\": [] }, \"outputs\": [], \"source\": [ \"# Create an instance\", \"qb = QuantBook()\", | CODE |
| MEDIUM | Tests/Python/PythonPackagesTests.cs | 85 | # Initialize dataframe object, specify time axis and variable names | COMMENT |
| MEDIUM | Tests/Python/PythonPackagesTests.cs | 353 | # Create a model (can be any object) | COMMENT |
| MEDIUM | Tests/Python/PythonPackagesTests.cs | 487 | # Define the models for the nuisance functions | COMMENT |
| MEDIUM | Tests/Python/PythonPackagesTests.cs | 649 | # Define the model hyperparameters | COMMENT |
| MEDIUM | Tests/Python/PythonPackagesTests.cs | 2012 | # Create the linear solver with the GLOP backend. | COMMENT |
| MEDIUM | Tests/Python/PythonPackagesTests.cs | 2015 | # Create the variables x and y. | COMMENT |
| MEDIUM | Tests/Python/PandasTests/PandasIndexingTests.py | 50 | # Create a new DF that has a plain ticker, test that our mapper doesn't break | COMMENT |
| MEDIUM | …hm.Python/NumeraiSignalExportDemonstrationAlgorithm.py | 41 | # Create a Scheduled Event to submit signals every trading day at 13:00 UTC | COMMENT |
| MEDIUM | …reStopMarketOrderOnExtendedHoursRegressionAlgorithm.py | 35 | # This method is opened 2 new orders by scheduler | COMMENT |
| MEDIUM | Algorithm.Python/CustomDataBitcoinAlgorithm.py | 31 | # Define the symbol and "type" of our generic data: | COMMENT |
| MEDIUM | Algorithm.Python/CustomPartialFillModelAlgorithm.py | 56 | # Create the object | COMMENT |
| MEDIUM | Algorithm.Python/MarginCallEventsAlgorithm.py | 59 | # This method is called when portfolio.margin_remaining is under 5% of your portfolio.total_portfolio_value | COMMENT |
| MEDIUM | …rithm.Python/CustomDataIndicatorExtensionsAlgorithm.py | 40 | # Define the symbol and "type" of our generic data | COMMENT |
| MEDIUM | Algorithm.Python/EmaCrossFuturesFrontMonthAlgorithm.py | 77 | # Create a new consolidator and register the indicators to it | COMMENT |
| MEDIUM | Algorithm.Python/IndicatorSuiteAlgorithm.py | 103 | # The following methods will add multiple charts to the algorithm output. | COMMENT |
| MEDIUM | …thon/HistoryWithCustomDataSourceRegressionAlgorithm.py | 49 | # Create a new symbol as equity so we find the existing data files | COMMENT |
| MEDIUM | ….Python/CrunchDAOSignalExportDemonstrationAlgorithm.py | 46 | # Create a Scheduled Event to submit signals every monday before the market opens | COMMENT |
| MEDIUM | Algorithm.Python/CustomDataNIFTYAlgorithm.py | 30 | # Define the symbol and "type" of our generic data: | COMMENT |
| MEDIUM | …ython/Collective2SignalExportDemonstrationAlgorithm.py | 41 | # Create a new PortfolioTarget for each symbol, assign it an initial amount of 0.05 and save it in self.targets | COMMENT |
| MEDIUM | Algorithm.Python/CustomIndicatorAlgorithm.py | 29 | # Create a QuantConnect indicator and a python custom indicator for comparison | COMMENT |
| MEDIUM⚡ | …orithm.Python/CustomConsolidatorRegressionAlgorithm.py | 31 | #Create a 3:10PM custom quote bar consolidator | COMMENT |
| MEDIUM⚡ | …orithm.Python/CustomConsolidatorRegressionAlgorithm.py | 41 | #Create an indicator and register a consolidator to it | COMMENT |
| MEDIUM | Algorithm.Python/BasicTemplateOptionsPriceModel.py | 38 | # Define the Option Price Model | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | Research/start.py | 46 | except NameError: | CODE |
| HIGH | …lackLittermanOptimizationPortfolioConstructionModel.py | 266 | except: | CODE |
| HIGH | Common/AlgorithmImports.py | 94 | except: | CODE |
| HIGH | Common/PandasMapper.py | 83 | except KeyError as e: | CODE |
| HIGH | …hm.Python/BracketOrderLimitEntryRegressionAlgorithm.py | 61 | except ArgumentException: | CODE |
| HIGH | …thm.Python/BasicTemplateCryptoFutureHourlyAlgorithm.py | 32 | except: | CODE |
| HIGH | Algorithm.Python/BasicTemplateCryptoFutureAlgorithm.py | 32 | except: | CODE |
| HIGH | …ython/OptionChainStrategyFiltersRegressionAlgorithm.py | 60 | except ArgumentException: | CODE |
| HIGH | …uestNotAllowedWithTickResolutionRegressionAlgorithm.py | 52 | except InvalidOperationException: | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | Tests/Python/PythonPackagesTests.cs | 993 | # specifying a single input parameter. In this example, we just pass the random | COMMENT |
| HIGH | Algorithm.Python/FuturesMomentumAlgorithm.py | 18 | ### In this example, we demostrate how to trade futures contracts using | COMMENT |
| HIGH | Algorithm.Python/DataConsolidationAlgorithm.py | 22 | ### In this example we show one of the simplest consolidators, the TradeBarConsolidator. | COMMENT |
| HIGH | Algorithm.Python/CustomDataUniverseAlgorithm.py | 18 | ### and load data using the universe selection feature. In this example we | COMMENT |
| HIGH | Algorithm.Python/MovingAverageCrossAlgorithm.py | 17 | ### In this example we look at the canonical 15/30 day moving average cross. This algorithm | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | …Framework/Execution/StandardDeviationExecutionModel.py | 44 | CODE | |
| LOW | Algorithm.Framework/Execution/SpreadExecutionModel.py | 29 | CODE | |
| LOW | …/Execution/VolumeWeightedAveragePriceExecutionModel.py | 31 | CODE | |
| LOW | …folio/AccumulativeInsightPortfolioConstructionModel.py | 44 | CODE | |
| LOW | …lackLittermanOptimizationPortfolioConstructionModel.py | 83 | CODE | |
| LOW | …lackLittermanOptimizationPortfolioConstructionModel.py | 223 | CODE | |
| LOW | …ork/Alphas/PearsonCorrelationPairsTradingAlphaModel.py | 39 | CODE | |
| LOW | Algorithm.Framework/Alphas/EmaCrossAlphaModel.py | 36 | CODE | |
| LOW | …ework/Risk/MaximumSectorExposureRiskManagementModel.py | 30 | CODE | |
| LOW | Algorithm/Execution/ImmediateExecutionModel.py | 26 | CODE | |
| LOW | Algorithm.Python/UpdateOrderRegressionAlgorithm.py | 53 | CODE | |
| LOW | …ConsolidateHourBarsIntoDailyBarsRegressionAlgorithm.py | 42 | CODE | |
| LOW | Algorithm.Python/FuturesMomentumAlgorithm.py | 49 | CODE | |
| LOW | Algorithm.Python/ObjectStoreExampleAlgorithm.py | 76 | CODE | |
| LOW | …thon/CustomDataUniverseScheduledRegressionAlgorithm.py | 51 | CODE | |
| LOW | Algorithm.Python/BubbleAlgorithm.py | 65 | CODE | |
| LOW | ….Python/FutureOptionPutITMExpiryRegressionAlgorithm.py | 56 | CODE | |
| LOW | …orithm.Python/OptionOpenInterestRegressionAlgorithm.py | 36 | CODE | |
| LOW | …Python/FutureOptionCallITMExpiryRegressionAlgorithm.py | 57 | CODE | |
| LOW | Algorithm.Python/BasicTemplateCryptoAlgorithm.py | 63 | CODE | |
| LOW | …orithm.Python/FractionalQuantityRegressionAlgorithm.py | 44 | CODE | |
| LOW | …ython/SecuritySessionWithFuturesRegressionAlgorithm.py | 38 | CODE | |
| LOW | …thm.Python/ExpiryHelperAlphaModelFrameworkAlgorithm.py | 51 | CODE | |
| LOW | Algorithm.Python/BasicTemplateEurexFuturesAlgorithm.py | 87 | CODE | |
| LOW | Algorithm.Python/IndiaDataRegressionAlgorithm.py | 46 | CODE | |
| LOW | Algorithm.Python/IndiaDataRegressionAlgorithm.py | 56 | CODE | |
| LOW | Algorithm.Python/ComboOrderTicketDemoAlgorithm.py | 39 | CODE | |
| LOW | Algorithm.Python/OptionRenameRegressionAlgorithm.py | 35 | CODE | |
| LOW | …hon/FutureOptionWithFutureFilterRegressionAlgorithm.py | 27 | CODE | |
| LOW | …ithm.Python/ConstituentsUniverseRegressionAlgorithm.py | 42 | CODE | |
| LOW | …/CanLiquidateWithOrderPropertiesRegressionAlgorithm.py | 29 | CODE | |
| LOW | ….Python/NullMarginMultipleOrdersRegressionAlgorithm.py | 37 | CODE | |
| LOW | …thm.Python/ContingentOrderCancelRegressionAlgorithm.py | 33 | CODE | |
| LOW | …orithm.Python/CustomDataUniverseRegressionAlgorithm.py | 49 | CODE | |
| LOW | Algorithm.Python/ComboOrdersFillModelAlgorithm.py | 45 | CODE | |
| LOW | …thm.Python/ContingentOrderUpdateRegressionAlgorithm.py | 31 | CODE | |
| LOW | Algorithm.Python/Alphas/RebalancingLeveragedETFAlpha.py | 72 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | Optimizer/Analysis/OptimizationAnalyzer.cs | 83 | // ── Aggregate helpers ──────────────────────────────────────────────────── | COMMENT |
| MEDIUM | Tests/Optimizer/Analysis/OptimizationAnalyzerTests.cs | 177 | // ── helpers ────────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | Tests/Common/Brokerages/WebullBrokerageModelTests.cs | 100 | // ── CanSubmitOrder — Option/IndexOption TimeInForce restrictions ──────── | COMMENT |
| MEDIUM | Tests/Common/Brokerages/WebullBrokerageModelTests.cs | 171 | // ── CanSubmitOrder — OutsideRegularTradingHours ────────────────────────── | COMMENT |
| MEDIUM | Engine/Results/Analysis/ResultsAnalyzer.cs | 205 | // ── Test chain ──────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | Engine/Results/Analysis/ResultsAnalyzer.cs | 567 | // ── 1. backtest equity from "Strategy Equity" chart ────────────────── | COMMENT |
| MEDIUM | Engine/Results/Analysis/ResultsAnalyzer.cs | 579 | // ── 2. Benchmark from SPY history ───────────────────────────────────── | COMMENT |
| MEDIUM | Engine/Results/Analysis/ResultsAnalyzer.cs | 599 | // ── 3. Resample both to daily data points ──────────────────────────── | COMMENT |
| MEDIUM | Engine/Results/Analysis/ResultsAnalyzer.cs | 608 | // ── 4. Align the two curves on the same timestamps ─────────────────── | COMMENT |
| MEDIUM | …alysis/Analyses/TakeProfitAndStopLossOrdersAnalysis.cs | 87 | // ── Sub-analysis 1: both TP and SL filled ──────────────────────────────────────── | COMMENT |
| MEDIUM | …sAnalyses/ExchangeNotOpenOrderResponseErrorAnalysis.cs | 72 | // ── Sub-analysis: exercise while exchange not open ──────────────────────────────── | COMMENT |
| MEDIUM | …sAnalyses/ExchangeNotOpenOrderResponseErrorAnalysis.cs | 94 | // ── Sub-analysis: MOC order for Future / FOP ───────────────────────────────────── | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | …ckMonthOptionUsingCalendarSpreadRegressionAlgorithm.cs | 77 | // Step 1: short front month put | COMMENT |
| LOW⚡ | …ckMonthOptionUsingCalendarSpreadRegressionAlgorithm.cs | 83 | // Step 2: roll out front month put to back month put using a calendar spread. | COMMENT |
| LOW | …arp/FutureOptionWithFutureFilterRegressionAlgorithm.cs | 38 | // Not all future contracts have option chains, so we need to check if the contract is in the option | COMMENT |
| LOW | …uidatingMultipleOptionStrategiesRegressionAlgorithm.cs | 84 | // Step 1: buy spreads | COMMENT |
| LOW | …uidatingMultipleOptionStrategiesRegressionAlgorithm.cs | 116 | // Step 2: liquidate spreads | COMMENT |
| LOW⚡ | Tests/Brokerages/OrderCrossingBrokerageTests.cs | 475 | // Step 1: Create order request under the hood of any brokerage | COMMENT |
| LOW⚡ | Tests/Brokerages/OrderCrossingBrokerageTests.cs | 479 | // Step 2: Place the order request, paying attention to the flag 'isPlaceOrderWithoutLeanEvent' | COMMENT |
| LOW⚡ | Tests/Brokerages/OrderCrossingBrokerageTests.cs | 482 | // Step 3: Return the result of placing the order | COMMENT |
| LOW | …hon/FutureOptionWithFutureFilterRegressionAlgorithm.py | 31 | # Not all future contracts have option chains, so we need to check if the contract is in the option chai | COMMENT |
| LOW | Engine/AlgorithmManager.cs | 224 | // If backtesting/warmup, we need to check if there are realtime events in the past | COMMENT |
| LOW | Engine/AlgorithmManager.cs | 939 | // we need to check if the security was removed. | COMMENT |
| LOW | Engine/DataFeeds/DateChangeTimeKeeper.cs | 203 | // which already passed if we are moving on to the next data date. So we need to check if we need to emi | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | Algorithm.CSharp/IndicatorHistoryAlgorithm.cs | 61 | // Let's log the BB values for the last 20 days, for demonstration purposes on how it can be enumerated | COMMENT |
| MEDIUM | Algorithm.CSharp/SecurityCustomPropertiesAlgorithm.cs | 111 | /// This custom fee is implemented for demonstration purposes only. | COMMENT |
| LOW | Common/Data/DynamicData.cs | 194 | // don't forget to add the dynamic members! | COMMENT |
| MEDIUM | Algorithm.Python/SecurityCustomPropertiesAlgorithm.py | 76 | '''This custom fee is implemented for demonstration purposes only.''' | STRING |
| MEDIUM | Algorithm.Python/IndicatorHistoryAlgorithm.py | 45 | # Let's log the BB values for the last 20 days, for demonstration purposes on how it can be enumerated | COMMENT |
| MEDIUM | Algorithm.Python/IndicatorSuiteAlgorithm.py | 18 | ### framework you can use for designing an algorithm. | COMMENT |
| MEDIUM | Algorithm.Python/BasicTemplateAlgorithm.py | 18 | ### framework you can use for designing an algorithm. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | …ckMonthOptionUsingCalendarSpreadRegressionAlgorithm.cs | 77 | // Step 1: short front month put | COMMENT |
| LOW⚡ | …ckMonthOptionUsingCalendarSpreadRegressionAlgorithm.cs | 83 | // Step 2: roll out front month put to back month put using a calendar spread. | COMMENT |
| LOW | …uidatingMultipleOptionStrategiesRegressionAlgorithm.cs | 84 | // Step 1: buy spreads | COMMENT |
| LOW | …uidatingMultipleOptionStrategiesRegressionAlgorithm.cs | 116 | // Step 2: liquidate spreads | COMMENT |
| LOW⚡ | Tests/Brokerages/OrderCrossingBrokerageTests.cs | 475 | // Step 1: Create order request under the hood of any brokerage | COMMENT |
| LOW⚡ | Tests/Brokerages/OrderCrossingBrokerageTests.cs | 479 | // Step 2: Place the order request, paying attention to the flag 'isPlaceOrderWithoutLeanEvent' | COMMENT |
| LOW⚡ | Tests/Brokerages/OrderCrossingBrokerageTests.cs | 482 | // Step 3: Return the result of placing the order | COMMENT |
| LOW | Engine/AlgorithmManager.cs | 922 | // NOTE: This method assumes option contracts have the same core trading hours as their underlying contract | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | …k/Portfolio/MeanReversionPortfolioConstructionModel.py | 154 | v_{t+1} = arg min || v - v_{t+1} || ^ 2 | STRING |
| HIGH | Common/PandasMapper.py | 105 | # Try the original args; if true just return true | COMMENT |
| HIGH | …thon/HistoryWithCustomDataSourceRegressionAlgorithm.py | 38 | if not aapl_history.equals(spy_history): | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | find_datasource_repos.py | 154 | except Exception as e: | CODE |
| LOW⚡ | Tests/Python/AlgorithmImportsTests.cs | 44 | except Exception: | CODE |
| LOW⚡ | Tests/Python/AlgorithmImportsTests.cs | 52 | except Exception: | CODE |
| MEDIUM | Tests/Python/AlgorithmImportsTests.cs | 41 | def except_clause_catches_python_exceptions(): | CODE |
| MEDIUM | Tests/Python/AlgorithmImportsTests.cs | 49 | def except_clause_catches_clr_exceptions(action): | CODE |
| LOW | …eFromMultipleTickTypeTickHistoryRegressionAlgorithm.py | 35 | except Exception as e: | CODE |
| LOW | …m.Python/PythonDictionaryFeatureRegressionAlgorithm.py | 131 | except Exception as e: | CODE |
| LOW | Algorithm.Python/PandasDataFrameHistoryAlgorithm.py | 134 | except Exception as e: | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | Algorithm.Python/DropboxCoarseFineAlgorithm.py | 62 | # Check if contains the row we need | COMMENT |
| LOW | …gorithm.Python/BasicTemplateFutureRolloverAlgorithm.py | 57 | # Check if information in SymbolData class and new slice data are ready for trading | COMMENT |
| LOW | Algorithm.Python/TrainingExampleAlgorithm.py | 32 | # Set TrainingMethod to be executed immediately | COMMENT |
| LOW | Algorithm.Python/TrainingExampleAlgorithm.py | 35 | # Set TrainingMethod to be executed at 8:00 am every Sunday | COMMENT |
| LOW | ….Python/Alphas/GasAndCrudeOilEnergyCorrelationAlpha.py | 92 | ## Check if Natural Gas returns are greater than the threshold we've set | COMMENT |
| LOW | Algorithm.Python/Alphas/RebalancingLeveragedETFAlpha.py | 89 | # Check if the returns are > 1% at 14.15 | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | …lackLittermanOptimizationPortfolioConstructionModel.py | 30 | CODE | |
| LOW | Report/ReportCharts.py | 138 | CODE | |
| LOW | Report/ReportCharts.py | 265 | CODE | |
| LOW | Report/ReportCharts.py | 656 | CODE | |
| LOW | Report/ReportCharts.py | 748 | CODE | |
| LOW | Report/ReportCharts.py | 973 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | Research/start.py | 17 | # Usage: | COMMENT |
| LOW | Tests/Brokerages/OrderCrossingBrokerageTests.cs | 546 | /// // Example usage | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | Algorithm.Python/RangeConsolidatorAlgorithm.py | 35 | def set_start_and_end_dates(self) -> None: | CODE |
| LOW | …m.Python/OptionModelsConsistencyRegressionAlgorithm.py | 43 | def set_models(self, security: Security) -> None: | CODE |
| LOW | Algorithm.Python/CompleteOrderTagUpdateAlgorithm.py | 83 | def update_order_tag(self, ticket: OrderTicket, tag: str, error_message_prefix: str) -> None: | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | Report/config.example.json | 5 | "strategy-description": "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut | CODE |
| LOW | Report/config.example.json | 5 | "strategy-description": "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | Optimizer/Strategies/OptimizationStrategySettings.cs | 26 | /// TODO: implement | COMMENT |