{"paper_id":"2412.18405","title":"Generalized Mean Absolute Directional Loss as a Solution to Overfitting and High Transaction Costs in Machine Learning Models Used in High-Frequency Algorithmic Investment Strategies","authors":["Jakub Michańków","Paweł Sakowski","Robert Ślepaczuk"],"paper_date":"2024-12-24","paper_type":"methodological","paper_url":"https://arxiv.org/pdf/2412.18405v1","page_url":"https://thequant.space/flowcharts/generalized-mean-absolute-directional-loss-as-a-solution-to/","scores":{"empirical_rigor":8,"math_complexity":7.5,"quadrant":"Holy Grail"},"proposes":{"status":"available","statement":"The paper proposes the Generalized Mean Absolute Directional Loss (GMADL) function as a new loss for training machine learning models in high‑frequency algorithmic trading.","quote":"Regardless of the selected asset class and the level of model complexity (Transformer versus LSTM versus Perceptron/RNN), the GMADL loss function produces superior results than standard MSE-type loss functions and has better numerical properties in the context of optimization than MADL.","summary":"Regardless of the selected asset class and the level of model complexity (Transformer versus LSTM versus Perceptron/RNN), the GMADL loss function produces superior results than standard MSE-type loss functions and has better numerical properties in the context of optimization than MADL. Better…","strategy":null},"assumptions":{"status":"available","items":[{"assumption":"High‑frequency data entail substantial transaction costs that must be accounted for in the loss function.","type":"market","stated":"implied","quote":"What is important is that, through additional parameterization, GMADL also solves the problem of optimizing investment systems on high-frequency data in such a way that they focus on strategy variants that contain fewer transactions so that transaction costs do not reduce the effectiveness of a given strategy to zero. GMADL function - adaptability and scalability Taking into account the existence of transaction","support":"full"},{"assumption":"The loss function should be differentiable enough to allow gradient‑based optimization.","type":"model","stated":"implied","quote":"One of the primary challenges lies in gradient optimization during the learning process. The reliance on absolute and sign functions introduces non-differentiability at zero, creating complications for smooth gradient-based training.","support":"full"},{"assumption":"Directional accuracy and magnitude of returns are more relevant for investment performance than pure point‑forecast error.","type":"statistical","stated":"explicit","quote":"We highlighted that standard error metrics fail to capture the effectiveness of forecasts for generating investment signals. These metrics focus only on forecast accuracy, penalizing all errors equally, regardless of direction, or consider only directional accuracy, ignoring error magnitude.","support":"full"}]},"datasets":{"status":"available","items":[{"name":"Bitcoin daily simple returns","provider":null,"kind":"crypto-onchain","access":"unknown","period":null,"universe":null,"quote":"Then, in the Results section (in the second version of this paper), we show an empirical comparison of the use of the MADL function and the classical forecast error function (MAE) in two time series: Bitcoin and Crude Oil daily simple returns.","support":"full"},{"name":"Crude Oil daily simple returns","provider":null,"kind":"other","access":"unknown","period":null,"universe":null,"quote":"Then, in the Results section (in the second version of this paper), we show an empirical comparison of the use of the MADL function and the classical forecast error function (MAE) in two time series: Bitcoin and Crude Oil daily simple returns.","support":"full"}],"known":[],"sample":{"start":null,"end":null,"market":null,"asset_class":null,"frequency":null},"data_resolution":"none"},"transaction_costs":{"status":"not_applicable","modeled":"n/a","headline_net_of_costs":null,"detail":null,"quote":null,"source":"front_matter","rule":"R4a","candidates":{"front_matter":"n/a","evidence_card":"partial","evidence_card_quoted":true},"card_detail":"The paper discusses parameterizing the loss (a and b) to reduce the number of transactions and mentions transaction costs as a factor, but does not embed a specific cost model in the headline results.","card_quote":"What is important is that, through additional parameterization, GMADL also solves the problem of optimizing investment systems on high-frequency data in such a way that they focus on strategy variants that contain fewer transactions so that transaction costs do not reduce the effectiveness of a given strategy to zero. GMADL function - adaptability and scalability Taking into account the existence of transaction","meaning":"the paper reports no trading or execution result; the cost the extractor found is a model parameter"},"results":{"status":"available","evaluation_type":"none","findings":[{"finding":"GMADL yields superior results compared with standard MSE‑type loss functions and the original MADL across asset classes and model complexities.","kind":"performance","quote":"Regardless of the selected asset class and the level of model complexity (Transformer versus LSTM versus Perceptron/RNN), the GMADL loss function produces superior results than standard MSE-type loss functions and has better numerical properties in the context of optimization than MADL.","support":"full"},{"finding":"Empirical tests on Bitcoin and Crude Oil daily returns show that GMADL outperforms the classical MAE loss.","kind":"performance","quote":"Then, in the Results section (in the second version of this paper), we show an empirical comparison of the use of the MADL function and the classical forecast error function (MAE) in two time series: Bitcoin and Crude Oil daily simple returns.","support":"full"},{"finding":"The additional parameterization (a, b) enables the loss to focus on strategies with fewer transactions, mitigating the impact of transaction costs.","kind":"theoretical","quote":"What is important is that, through additional parameterization, GMADL also solves the problem of optimizing investment systems on high-frequency data in such a way that they focus on strategy variants that contain fewer transactions so that transaction costs do not reduce the effectiveness of a given strategy to zero. GMADL function - adaptability and scalability Taking into account the existence of transaction","support":"full"},{"finding":"Using exponential smoothing with parameters a and b makes GMADL more differentiable and stabilizes optimization in diverse market environments.","kind":"theoretical","quote":"Using exponential smoothing along with parameters a and b, we have shown how GMADL offers a differentiable and adaptable framework, thus enhancing the stability and efficiency of optimization processes in diverse market environments.","support":"full"},{"finding":"GMADL can be scaled to high‑frequency, minute‑by‑minute or tick‑level forecasting contexts while maintaining adaptability across asset classes.","kind":"performance","quote":"The result is a highly scalable loss function that not only caters to traditional daily or weekly trading horizons but also excels in granular, minute-by-minute, or even tick-level forecasting contexts. 3.5.","support":"full"}],"reported_performance":null,"out_of_sample":{"method":"none","headline_out_of_sample":null}},"independent_evidence":{"status":"none_found","supports":[],"contradicts":[],"qualifies":[],"compared_with":37,"citations":{"cited_by_in_corpus":1,"by_independent_authors":0,"how_cited":{"used_as_baseline":0,"uses_method_or_data":0,"extends":0,"discusses_findings":0,"mentions":0,"unclassified":1},"independent_papers":[],"scope":"Citations between papers in this corpus only; citations from outside it are not counted."}},"implementation":{"status":"available","public":false,"code_url":null,"note":"No repository presented by the authors as their own was found in the paper. Absence here is not proof that no code exists."},"replication":{"status":"none_found","card":null,"note":"No replication of this paper has been run by thequant.space yet."},"extraction":{"text_source":"fulltext","model":"openai/gpt-oss-120b","version":2,"extracted_at":"2026-11-14T19:53:30Z"},"provenance":{"claims":"Everything here is what the authors state in the paper. Nothing was re-run or reproduced by the platform.","quotes":"Assumptions, datasets, cost detail and findings were extracted by a language model. Every quote is verbatim paper text. Where an item has `support`, \"full\" means every figure in it appears in the quoted sentences and \"partial\" means a figure is stated elsewhere in the paper; items with a figure found nowhere in the paper were discarded.","datasets_known":"datasets.known lists well-known vendors and public datasets by a stable id, found by a dictionary over the full text where the sentence says the data is used; it is independent of the model and covers only names in the dictionary.","flags":"transaction_costs.modeled, results.evaluation_type and results.out_of_sample.method are platform classifications (structured-decision models); see https://thequant.space/score-guide/#penalty-flags","comparisons":"supports / contradicts / qualifies are a language model's reading of two papers' quoted findings, restricted to closely related papers that share no author. They are pointers to read, not verified replications, and coverage is partial.","implementation":"code_url is a repository the paper itself presents as its own (rule-scored, ambiguous cases judged by a model), checked for liveness when it was recorded."},"docs":"https://thequant.space/agents/"}