Interpreting Time Series Forecasts with LIME and SHAP:A Case Study on the Air Passengers Dataset | Research Square window.SnipcartSettings = { analytics: { enabled: false } }; (function() { var accessVector = localStorage.getItem('access_vector') || ''; window.dataLayer = window.dataLayer || []; if (accessVector) { window.dataLayer.push({ user: { profile: { profileInfo: { snid: accessVector } } } }); } })(); (function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src='https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);})(window,document,'script','dataLayer','GTM-K279D39R'); Browse Preprints In Review Journals COVID-19 Preprints AJE Video Bytes Research Tools Research Promotion AJE Professional Editing AJE Rubriq About Preprint Platform In Review Editorial Policies Our Team Advisory Board Help Center Sign In Submit a Preprint Cite Share Download PDF Research Article Interpreting Time Series Forecasts with LIME and SHAP:A Case Study on the Air Passengers Dataset Manish Shukla This is a preprint; it has not been peer reviewed by a journal. https://doi.org/ 10.21203/rs.3.rs-7358158/v1 This work is licensed under a CC BY 4.0 License Status: Posted Version 1 posted You are reading this latest preprint version Abstract Time-series forecasting underpins critical decisions across aviation, energy, retail and health. Classical autoregressive integrated moving average (ARIMA) models offer interpretability via coefficients but struggle with nonlinearities, whereas tree-based machine-learning models such as XGBoost deliver high accuracy but are often opaque. This paper presents a unified framework for interpreting time-series forecasts using local interpretable modelagnostic explanations (LIME) and SHapley additive exPlanations (SHAP). We convert a univariate series into a leakage-free supervised learning problem, train a gradient-boosted tree alongside an ARIMA baseline and apply post-hoc explainability. Using the Air Passengers dataset as a case study, we show that a small set of lagged features—particularly the twelve-month lag—and seasonal encodings explain most forecast variance. We contribute: (i) a methodology for applying LIME and SHAP to time series without violating chronology; (ii) theoretical exposition of the underlying algorithms; (iii) empirical evaluation with extensive analysis; and (iv) guidelines for practitioners. time series forecasting interpretability LIME SHAP ARIMA gradient boosting Air Passengers Full Text Additional Declarations No competing interests reported. Cite Share Download PDF Status: Posted Version 1 posted You are reading this latest preprint version Research Square lets you share your work early, gain feedback from the community, and start making changes to your manuscript prior to peer review in a journal. As a division of Research Square Company, we’re committed to making research communication faster, fairer, and more useful. We do this by developing innovative software and high quality services for the global research community. Our growing team is made up of researchers and industry professionals working together to solve the most critical problems facing scientific publishing. Also discoverable on Platform About Our Team In Review Editorial Policies Advisory Board Help Center Resources Author Services Accessibility API Access RSS feed Manage Cookie Preferences © Research Square 2026 | ISSN 2693-5015 (online) Privacy Policy Terms of Service Do Not Sell My Personal Information {"props":{"pageProps":{"initialData":{"identity":"rs-7358158","acceptedTermsAndConditions":true,"allowDirectSubmit":true,"archivedVersions":[],"articleType":"Research Article","associatedPublications":[],"authors":[{"id":499538479,"identity":"1aab9e24-940a-4f5f-88c6-5405b18eaafa","order_by":0,"name":"Manish Shukla","email":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAZAAAAAyAQMAAABI0h/eAAAABlBMVEX///8AAABVwtN+AAAACXBIWXMAAA7EAAAOxAGVKw4bAAABIElEQVRIie2PMUvDQBTHcwTMciHrBYvfQHggSIeCXyVB6HQWQXAMCYXLYHQvfolMwfHCgS4XMgkXujjpksFuLXRokkWFNOomcr/hPR68H//3DEOj+aNwFBqegc2wHbBjtR3GP1FQp4zchLcKGY75rExAeW3frxzHRZ5vHoIZyDx6RzTA7uLtOV1fEsOJb7w+5VTOPGFLcQVFNCcoE9g5pNdV0hxGZJH2KpyCQIz7aYnCRuHYvadThRsFyEW/UtaQb1jQKvM1ygIMlZxW2yFFUeA2M/20iFiTYmJQ1uNyMEXVIGwm/IXM2dhvfnETerAcAcF7fynpyao97E6eC7XKgjPHenqt6u3kyIlve5WveF3F0NXv1z+wXn6zrdFoNP+fHWEKbs9YYoqAAAAAAElFTkSuQmCC","orcid":"","institution":"","correspondingAuthor":true,"prefix":"","firstName":"Manish","middleName":"","lastName":"Shukla","suffix":""}],"badges":[],"createdAt":"2025-08-12 17:23:11","currentVersionCode":1,"declarations":"","doi":"10.21203/rs.3.rs-7358158/v1","doiUrl":"https://doi.org/10.21203/rs.3.rs-7358158/v1","draftVersion":[],"editorialEvents":[],"editorialNote":"","failedWorkflow":false,"files":[{"id":88975050,"identity":"5e66bee9-8e14-41ba-928d-b697691a54b4","added_by":"auto","created_at":"2025-08-13 10:11:43","extension":"pdf","order_by":1,"title":"","display":"","copyAsset":false,"role":"manuscript-pdf","size":361643,"visible":true,"origin":"","legend":"","description":"","filename":"TSBERTLIME.pdf","url":"https://assets-eu.researchsquare.com/files/rs-7358158/v1_covered_8c8ebb45-77ef-4098-8f0c-5e6db6736589.pdf"}],"financialInterests":"No competing interests reported.","formattedTitle":"Interpreting Time Series Forecasts with LIME and SHAP:A Case Study on the Air Passengers Dataset","fulltext":[],"fulltextSource":"","fullText":"","funders":[],"hasAdminPriorityOnWorkflow":false,"hasManuscriptDocX":false,"hasOptedInToPreprint":true,"hasPassedJournalQc":"","hasAnyPriority":true,"hideJournal":true,"highlight":"","institution":"","isAcceptedByJournal":false,"isAuthorSuppliedPdf":false,"isDeskRejected":"","isHiddenFromSearch":false,"isInQc":false,"isInWorkflow":false,"isPdf":true,"isPdfUpToDate":true,"isWithdrawnOrRetracted":false,"journal":{"display":true,"email":"
[email protected]","identity":"researchsquare","isNatureJournal":false,"hasQc":true,"allowDirectSubmit":true,"externalIdentity":"","sideBox":"","snPcode":"","submissionUrl":"/submission","title":"Research Square","twitterHandle":"researchsquare","acdcEnabled":true,"dfaEnabled":false,"editorialSystem":"","reportingPortfolio":"","inReviewEnabled":false,"inReviewRevisionsEnabled":true},"keywords":"time series forecasting, interpretability, LIME, SHAP, ARIMA, gradient boosting, Air Passengers","lastPublishedDoi":"10.21203/rs.3.rs-7358158/v1","lastPublishedDoiUrl":"https://doi.org/10.21203/rs.3.rs-7358158/v1","license":{"name":"CC BY 4.0","url":"https://creativecommons.org/licenses/by/4.0/"},"manuscriptAbstract":"Time-series forecasting underpins critical decisions across aviation, energy, retail and health.\nClassical autoregressive integrated moving average (ARIMA) models offer interpretability\nvia coefficients but struggle with nonlinearities, whereas tree-based machine-learning models\nsuch as XGBoost deliver high accuracy but are often opaque. This paper presents\na unified framework for interpreting time-series forecasts using local interpretable modelagnostic\nexplanations (LIME) and SHapley additive exPlanations (SHAP). We convert a\nunivariate series into a leakage-free supervised learning problem, train a gradient-boosted\ntree alongside an ARIMA baseline and apply post-hoc explainability. Using the Air Passengers\ndataset as a case study, we show that a small set of lagged features—particularly the\ntwelve-month lag—and seasonal encodings explain most forecast variance. We contribute:\n(i) a methodology for applying LIME and SHAP to time series without violating chronology;\n(ii) theoretical exposition of the underlying algorithms; (iii) empirical evaluation with\nextensive analysis; and (iv) guidelines for practitioners.","manuscriptTitle":"Interpreting Time Series Forecasts with LIME and SHAP:A Case Study on the Air Passengers Dataset","msid":"","msnumber":"","nonDraftVersions":[{"code":1,"date":"2025-08-13 10:03:38","doi":"10.21203/rs.3.rs-7358158/v1","editorialEvents":[{"type":"communityComments","content":0}],"status":"published","journal":{"display":true,"email":"
[email protected]","identity":"researchsquare","isNatureJournal":false,"hasQc":true,"allowDirectSubmit":true,"externalIdentity":"","sideBox":"","snPcode":"","submissionUrl":"/submission","title":"Research Square","twitterHandle":"researchsquare","acdcEnabled":true,"dfaEnabled":false,"editorialSystem":"","reportingPortfolio":"","inReviewEnabled":false,"inReviewRevisionsEnabled":true}}],"origin":"","ownerIdentity":"c92a1b4f-b271-46ce-bad1-0da7e17b67f2","owner":[],"postedDate":"August 13th, 2025","published":true,"recentEditorialEvents":[],"rejectedJournal":[],"revision":"","amendment":"","status":"posted","subjectAreas":[],"tags":[],"updatedAt":"2025-10-27T13:48:18+00:00","versionOfRecord":[],"versionCreatedAt":"2025-08-13 10:03:38","video":"","vorDoi":"","vorDoiUrl":"","workflowStages":[]},"version":"v1","identity":"rs-7358158","journalConfig":"researchsquare"},"__N_SSP":true},"page":"/article/[identity]/[[...version]]","query":{"redirect":"/article/rs-7358158","identity":"rs-7358158","version":["v1"]},"buildId":"8U1c8b4HqxoKbykW_rLl7","isFallback":false,"isExperimentalCompile":false,"dynamicIds":[84888],"gssp":true,"scriptLoader":[]}
Text is read by the "Ask this paper" AI Q&A widget below.
Extraction quality varies by source — PMC NXML preserves structure
cleanly, OA-HTML may include some navigation residue, and OA-PDF can
have broken hyphenation. The publisher copy
(via DOI)
is the canonical version.