{"id":472,"date":"2022-08-16T08:17:27","date_gmt":"2022-08-16T08:17:27","guid":{"rendered":"https:\/\/eodhd.com\/financial-academy\/?p=472"},"modified":"2025-02-05T11:13:01","modified_gmt":"2025-02-05T11:13:01","slug":"obtaining-stocks-data-for-the-analysis-in-python","status":"publish","type":"post","link":"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python","title":{"rendered":"Obtaining Stocks Data for the Analysis in Python"},"content":{"rendered":"\n<p><strong>Preface: <\/strong>In this video series Matt shows how to use the EODHD Financial APIs for the Stock Analysis with Python.<\/p>\n\n\n\n<p><strong>Don&#8217;t forget to explore other 2 Parts to learn more:<\/strong><br>Part 1 Obtaining Stocks Data for the Analysis in Python<br>Part 2 <a href=\"https:\/\/eodhistoricaldata.com\/financial-academy\/data-processing-samples-and-manuals\/processing-stocks-data-in-python-for-the-analysis\/\">Processing Stocks Data in Python for the Analysis<\/a><br>Part 3 <a href=\"https:\/\/eodhistoricaldata.com\/financial-academy\/extracting-the-knowledge-from-the-data\/filtering-and-visualizing-the-stocks-data-analysis-results-in-python\/\">Filtering and visualizing the Stocks Data Analysis results in Python<\/a><\/p>\n\n\n\n<figure class=\"wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<div class=\"entry-content-asset\"><iframe loading=\"lazy\" title=\"**Python Stock Tickers: Download ALL Exchange Data (API to Pandas DataFrame) Part 1** \ud83d\udc0d\" width=\"980\" height=\"551\" src=\"https:\/\/www.youtube.com\/embed\/bKUZrBAzqJs?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" referrerpolicy=\"strict-origin-when-cross-origin\" allowfullscreen><\/iframe><\/div>\n<\/div><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p class=\"has-text-align-center\"><a class=\"maxbutton-1 maxbutton maxbutton-subscribe-to-api external-css btn\" href=\"https:\/\/eodhd.com\/register\"><span class='mb-text'>Register &amp; Get Data<\/span><\/a><\/p>\n\n\n\n            <div class=\"code__wrapper\">\n                <div class=\"code__content\">\n                    \n<pre class=\"wp-block-code has-white-color has-black-background-color has-text-color has-background\"><code lang=\"python\" class=\"language-python\">import json\nimport pandas as pd\nimport requests\n\ndef get_exchange_data(key, exchange='NYSE'):\n    \"\"\"\n    returns metadata for a specific exchange\n    available: US, NASDAQ, OTCBB, PINK, BATS\n    \"\"\"\n    endpoint = f\"https:\/\/eodhistoricaldata.com\/api\/exchange-symbol-list\/\"\n    endpoint += f\"{exchange}?api_token={key}&amp;fmt=json\"\n    print(\"Downloading data\")\n    call =requests.get(endpoint).text\n    exchange_data = pd.DataFrame(json.loads(call))\n    print(\"Completed\")\n    return exchange_data\n\ndef main():\n    key = open('api_token.txt').read()\n    print(get_exchange_data(key))\n\n\nif __name__ == '__main__':\n    main()\n<\/code><\/pre>\n\n                <\/div>\n                <div class=\"code__btns\">\n                    <button class=\"code__copy\" class=\"copy\" title=\"Copy url\">\n                        <svg class=\"code__copy__icon\" width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\">\n                            <use xlink:href=\"\/img\/icons\/copy.svg#copy\"><\/use>\n                        <\/svg>\n                        <img decoding=\"async\" class=\"code__copy__approve\" alt=\"\" src=\"\/img\/approve_ico.svg\" loading=\"eager\">\n                    <\/button>\n                <\/div>\n            <\/div>\n        \n\n\n<figure class=\"wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<div class=\"entry-content-asset\"><iframe loading=\"lazy\" title=\"Python Data Curation: Filter Stock Tickers by S&amp;P 500 &amp; Sector with Pandas | Part 2 \ud83d\udcca\" width=\"980\" height=\"551\" src=\"https:\/\/www.youtube.com\/embed\/KKVZHKDEKFA?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" referrerpolicy=\"strict-origin-when-cross-origin\" allowfullscreen><\/iframe><\/div>\n<\/div><\/figure>\n\n\n\n            <div class=\"code__wrapper\">\n                <div class=\"code__content\">\n                    \n<pre class=\"wp-block-code has-white-color has-black-background-color has-text-color has-background\"><code lang=\"python\" class=\"language-python\">import json\nimport pandas as pd\nimport requests\n\ndef get_security_type(exchange_data, type= \"Common Stock\"):\n    \"\"\"\n    Returns a list of filtered security types\n    Types available: Common Stock, ETF, Fund, Preferred Stock\n    \"\"\"\n    symbols = exchange_data[exchange_data.Type == type]\n    return symbols.Code.to_list()\n\ndef get_sp(symbols =True, sector= False):\n    \"\"\"\n    returns S&amp;P 500 metadata\n    Sectors: Communication Services, Consumer Discretionary, Consumer Staples,\n    Energy, Financials, Health Care, Industrials, Information Technology,\n    Materials, Real Estate, Utilities\n    \"\"\"\n    sp = pd.read_csv('sp500.csv')\n    if sector:\n        sp = sp[sp.Sector == sector]\n    if symbols:\n        return sp['Symbol']\n    else:\n        return sp        \n\ndef main():\n    key = open('api_token.txt').read()\n    print(get_security_type(get_exchange_data(key)))\n    print(get_sp(symbols=False, sector='Energy'))\n\nif __name__ == '__main__':\n    main()\n<\/code><\/pre>\n\n                <\/div>\n                <div class=\"code__btns\">\n                    <button class=\"code__copy\" class=\"copy\" title=\"Copy url\">\n                        <svg class=\"code__copy__icon\" width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\">\n                            <use xlink:href=\"\/img\/icons\/copy.svg#copy\"><\/use>\n                        <\/svg>\n                        <img decoding=\"async\" class=\"code__copy__approve\" alt=\"\" src=\"\/img\/approve_ico.svg\" loading=\"eager\">\n                    <\/button>\n                <\/div>\n            <\/div>\n        \n\n\n<figure class=\"wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<div class=\"entry-content-asset\"><iframe loading=\"lazy\" title=\"Python Download Historical Stock Data &amp; Save to CSV (eod Library &amp; Pandas) | Part 3 \ud83d\udcbe\" width=\"980\" height=\"551\" src=\"https:\/\/www.youtube.com\/embed\/emHY55Svxac?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" referrerpolicy=\"strict-origin-when-cross-origin\" allowfullscreen><\/iframe><\/div>\n<\/div><\/figure>\n\n\n\n            <div class=\"code__wrapper\">\n                <div class=\"code__content\">\n                    \n<pre class=\"wp-block-code has-white-color has-black-background-color has-text-color has-background\"><code lang=\"python\" class=\"language-python\">import datetime as dt\nfrom eod import EodHistoricalData\nimport json\nimport os\nimport pandas as pd\nimport requests\n\nDEFAULT_DATE = dt.date.today() - dt.timedelta(396)\nTODAY =dt.date.today()\n\ndef get_data(*tickers, key, path='data_files', date=DEFAULT_DATE):\n    \"\"\"\n    downloads and stores as csv price data for selected securities\n    \"\"\"\n    if not os.path.exists(f\"{os.getcwd()}\/{path}\"):\n        os.mkdir(path)\n    downloaded = 0\n    skipped = 0\n    tickers_skipped = []\n\n    client = EodHistoricalData(key)\n    for ticker in tickers:\n        try:\n            print(f\"Downloading {ticker}\")\n            df = pd.DataFrame(client.get_prices_eod(ticker, from_=date))\n            df.index = pd.DatetimeIndex(df.date)\n            df.drop(columns=['date'], inplace=True)\n            df.to_csv(f\"{path}\/{ticker}.csv\")\n            downloaded += 1\n        except:\n            print(f\"{ticker} not found, skipping...\")\n            skipped += 1\n            tickers_skipped.append(ticker)\n    print(\"Download completed\")\n    print(f\"Data download for {downloaded} securities\")\n    print(f\"{skipped} tickers skipped\")\n    if tickers_skipped:\n        print(\" Tickers skipped \".center(30, \"=\"))\n        for ticker in tickers_skipped:\n            print(ticker)                         \n\ndef main():\n    key = open('api_token.txt').read()\n    get_data(\"AAPL\", \"GOOG\",key= key, path= 'mine')\n\nif __name__ == '__main__':\n    main()\n<\/code><\/pre>\n\n                <\/div>\n                <div class=\"code__btns\">\n                    <button class=\"code__copy\" class=\"copy\" title=\"Copy url\">\n                        <svg class=\"code__copy__icon\" width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\">\n                            <use xlink:href=\"\/img\/icons\/copy.svg#copy\"><\/use>\n                        <\/svg>\n                        <img decoding=\"async\" class=\"code__copy__approve\" alt=\"\" src=\"\/img\/approve_ico.svg\" loading=\"eager\">\n                    <\/button>\n                <\/div>\n            <\/div>\n        \n\n\n<p><\/p>\n\n\n\n<p class=\"has-text-align-center\"><a class=\"maxbutton-1 maxbutton maxbutton-subscribe-to-api external-css btn\" href=\"https:\/\/eodhd.com\/register\"><span class='mb-text'>Register &amp; Get Data<\/span><\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Preface: In this video series Matt shows how to use the EODHD Financial APIs for the Stock Analysis with Python. Don&#8217;t forget to explore other 2 Parts to learn more:Part 1 Obtaining Stocks Data for the Analysis in PythonPart 2 Processing Stocks Data in Python for the AnalysisPart 3 Filtering and visualizing the Stocks Data [&hellip;]<\/p>\n","protected":false},"author":6,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[43],"tags":[51],"coding-language":[30],"ready-to-go-solution":[],"qualification":[31,33],"financial-apis-category":[36],"financial-apis-manuals":[47],"class_list":["post-472","post","type-post","status-publish","format-standard","hentry","category-how-to-get-stocks-data-examples","tag-youtube","coding-language-python","qualification-experienced","qualification-newbie","financial-apis-category-stock-market-prices","financial-apis-manuals-exchanges-data"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v21.9 (Yoast SEO v26.7) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>The Power of Python for Stocks Data Analysis | EODHD APIs Academy<\/title>\n<meta name=\"description\" content=\"Unlock the power of stock data analysis with Python. Learn how to analyze stock data using Python and make informed investment decisions\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Obtaining Stocks Data for the Analysis in Python\" \/>\n<meta property=\"og:description\" content=\"Unlock the power of stock data analysis with Python. Learn how to analyze stock data using Python and make informed investment decisions\" \/>\n<meta property=\"og:url\" content=\"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python\" \/>\n<meta property=\"og:site_name\" content=\"Financial Academy\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/eodhistoricaldata\" \/>\n<meta property=\"article:published_time\" content=\"2022-08-16T08:17:27+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-02-05T11:13:01+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/eodhd.com\/financial-academy\/wp-content\/uploads\/2022\/08\/Obtaining-Stocks-Data-for-the-Analysis-in-Python.png\" \/>\n\t<meta property=\"og:image:width\" content=\"800\" \/>\n\t<meta property=\"og:image:height\" content=\"450\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Matt Macarty\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@https:\/\/twitter.com\/mjmacarty\" \/>\n<meta name=\"twitter:site\" content=\"@EOD_data\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Matt Macarty\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python#article\",\"isPartOf\":{\"@id\":\"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python\"},\"author\":{\"name\":\"Matt Macarty\",\"@id\":\"https:\/\/eodhd.com\/financial-academy\/#\/schema\/person\/60415de1596098ca8152e233c446a992\"},\"headline\":\"Obtaining Stocks Data for the Analysis in Python\",\"datePublished\":\"2022-08-16T08:17:27+00:00\",\"dateModified\":\"2025-02-05T11:13:01+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python\"},\"wordCount\":83,\"publisher\":{\"@id\":\"https:\/\/eodhd.com\/financial-academy\/#organization\"},\"keywords\":[\"YouTube Videos\"],\"articleSection\":[\"How to Get Stocks Data Examples\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python\",\"url\":\"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python\",\"name\":\"The Power of Python for Stocks Data Analysis | EODHD APIs Academy\",\"isPartOf\":{\"@id\":\"https:\/\/eodhd.com\/financial-academy\/#website\"},\"datePublished\":\"2022-08-16T08:17:27+00:00\",\"dateModified\":\"2025-02-05T11:13:01+00:00\",\"description\":\"Unlock the power of stock data analysis with Python. Learn how to analyze stock data using Python and make informed investment decisions\",\"breadcrumb\":{\"@id\":\"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/eodhd.com\/financial-academy\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Obtaining Stocks Data for the Analysis in Python\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/eodhd.com\/financial-academy\/#website\",\"url\":\"https:\/\/eodhd.com\/financial-academy\/\",\"name\":\"Financial APIs Academy | EODHD\",\"description\":\"Financial Stock Market Academy\",\"publisher\":{\"@id\":\"https:\/\/eodhd.com\/financial-academy\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/eodhd.com\/financial-academy\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/eodhd.com\/financial-academy\/#organization\",\"name\":\"EODHD (EOD Historical Data)\",\"url\":\"https:\/\/eodhd.com\/financial-academy\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/eodhd.com\/financial-academy\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/eodhd.com\/financial-academy\/wp-content\/uploads\/2023\/12\/EODHD-Logo.png\",\"contentUrl\":\"https:\/\/eodhd.com\/financial-academy\/wp-content\/uploads\/2023\/12\/EODHD-Logo.png\",\"width\":159,\"height\":82,\"caption\":\"EODHD (EOD Historical Data)\"},\"image\":{\"@id\":\"https:\/\/eodhd.com\/financial-academy\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/www.facebook.com\/eodhistoricaldata\",\"https:\/\/x.com\/EOD_data\",\"https:\/\/www.reddit.com\/r\/EODHistoricalData\/\",\"https:\/\/eod-historical-data.medium.com\/\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/eodhd.com\/financial-academy\/#\/schema\/person\/60415de1596098ca8152e233c446a992\",\"name\":\"Matt Macarty\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/eodhd.com\/financial-academy\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/a323524269378edb9025ce263fb588b98fd68a6188e577b95d0bdfe6dd8ccc43?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/a323524269378edb9025ce263fb588b98fd68a6188e577b95d0bdfe6dd8ccc43?s=96&d=mm&r=g\",\"caption\":\"Matt Macarty\"},\"sameAs\":[\"https:\/\/linkedin.com\/in\/mjmacarty\",\"https:\/\/x.com\/https:\/\/twitter.com\/mjmacarty\"],\"url\":\"https:\/\/eodhd.com\/financial-academy\/author\/mattmacarty\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"The Power of Python for Stocks Data Analysis | EODHD APIs Academy","description":"Unlock the power of stock data analysis with Python. Learn how to analyze stock data using Python and make informed investment decisions","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python","og_locale":"en_US","og_type":"article","og_title":"Obtaining Stocks Data for the Analysis in Python","og_description":"Unlock the power of stock data analysis with Python. Learn how to analyze stock data using Python and make informed investment decisions","og_url":"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python","og_site_name":"Financial Academy","article_publisher":"https:\/\/www.facebook.com\/eodhistoricaldata","article_published_time":"2022-08-16T08:17:27+00:00","article_modified_time":"2025-02-05T11:13:01+00:00","og_image":[{"width":800,"height":450,"url":"https:\/\/eodhd.com\/financial-academy\/wp-content\/uploads\/2022\/08\/Obtaining-Stocks-Data-for-the-Analysis-in-Python.png","type":"image\/png"}],"author":"Matt Macarty","twitter_card":"summary_large_image","twitter_creator":"@https:\/\/twitter.com\/mjmacarty","twitter_site":"@EOD_data","twitter_misc":{"Written by":"Matt Macarty","Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python#article","isPartOf":{"@id":"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python"},"author":{"name":"Matt Macarty","@id":"https:\/\/eodhd.com\/financial-academy\/#\/schema\/person\/60415de1596098ca8152e233c446a992"},"headline":"Obtaining Stocks Data for the Analysis in Python","datePublished":"2022-08-16T08:17:27+00:00","dateModified":"2025-02-05T11:13:01+00:00","mainEntityOfPage":{"@id":"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python"},"wordCount":83,"publisher":{"@id":"https:\/\/eodhd.com\/financial-academy\/#organization"},"keywords":["YouTube Videos"],"articleSection":["How to Get Stocks Data Examples"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python","url":"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python","name":"The Power of Python for Stocks Data Analysis | EODHD APIs Academy","isPartOf":{"@id":"https:\/\/eodhd.com\/financial-academy\/#website"},"datePublished":"2022-08-16T08:17:27+00:00","dateModified":"2025-02-05T11:13:01+00:00","description":"Unlock the power of stock data analysis with Python. Learn how to analyze stock data using Python and make informed investment decisions","breadcrumb":{"@id":"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/eodhd.com\/financial-academy\/how-to-get-stocks-data-examples\/obtaining-stocks-data-for-the-analysis-in-python#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/eodhd.com\/financial-academy\/"},{"@type":"ListItem","position":2,"name":"Obtaining Stocks Data for the Analysis in Python"}]},{"@type":"WebSite","@id":"https:\/\/eodhd.com\/financial-academy\/#website","url":"https:\/\/eodhd.com\/financial-academy\/","name":"Financial APIs Academy | EODHD","description":"Financial Stock Market Academy","publisher":{"@id":"https:\/\/eodhd.com\/financial-academy\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/eodhd.com\/financial-academy\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/eodhd.com\/financial-academy\/#organization","name":"EODHD (EOD Historical Data)","url":"https:\/\/eodhd.com\/financial-academy\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/eodhd.com\/financial-academy\/#\/schema\/logo\/image\/","url":"https:\/\/eodhd.com\/financial-academy\/wp-content\/uploads\/2023\/12\/EODHD-Logo.png","contentUrl":"https:\/\/eodhd.com\/financial-academy\/wp-content\/uploads\/2023\/12\/EODHD-Logo.png","width":159,"height":82,"caption":"EODHD (EOD Historical Data)"},"image":{"@id":"https:\/\/eodhd.com\/financial-academy\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/eodhistoricaldata","https:\/\/x.com\/EOD_data","https:\/\/www.reddit.com\/r\/EODHistoricalData\/","https:\/\/eod-historical-data.medium.com\/"]},{"@type":"Person","@id":"https:\/\/eodhd.com\/financial-academy\/#\/schema\/person\/60415de1596098ca8152e233c446a992","name":"Matt Macarty","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/eodhd.com\/financial-academy\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/a323524269378edb9025ce263fb588b98fd68a6188e577b95d0bdfe6dd8ccc43?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/a323524269378edb9025ce263fb588b98fd68a6188e577b95d0bdfe6dd8ccc43?s=96&d=mm&r=g","caption":"Matt Macarty"},"sameAs":["https:\/\/linkedin.com\/in\/mjmacarty","https:\/\/x.com\/https:\/\/twitter.com\/mjmacarty"],"url":"https:\/\/eodhd.com\/financial-academy\/author\/mattmacarty"}]}},"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/pdOdVT-7C","jetpack_sharing_enabled":true,"acf":[],"_links":{"self":[{"href":"https:\/\/eodhd.com\/financial-academy\/wp-json\/wp\/v2\/posts\/472","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/eodhd.com\/financial-academy\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/eodhd.com\/financial-academy\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/eodhd.com\/financial-academy\/wp-json\/wp\/v2\/users\/6"}],"replies":[{"embeddable":true,"href":"https:\/\/eodhd.com\/financial-academy\/wp-json\/wp\/v2\/comments?post=472"}],"version-history":[{"count":4,"href":"https:\/\/eodhd.com\/financial-academy\/wp-json\/wp\/v2\/posts\/472\/revisions"}],"predecessor-version":[{"id":6220,"href":"https:\/\/eodhd.com\/financial-academy\/wp-json\/wp\/v2\/posts\/472\/revisions\/6220"}],"wp:attachment":[{"href":"https:\/\/eodhd.com\/financial-academy\/wp-json\/wp\/v2\/media?parent=472"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/eodhd.com\/financial-academy\/wp-json\/wp\/v2\/categories?post=472"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/eodhd.com\/financial-academy\/wp-json\/wp\/v2\/tags?post=472"},{"taxonomy":"coding-language","embeddable":true,"href":"https:\/\/eodhd.com\/financial-academy\/wp-json\/wp\/v2\/coding-language?post=472"},{"taxonomy":"ready-to-go-solution","embeddable":true,"href":"https:\/\/eodhd.com\/financial-academy\/wp-json\/wp\/v2\/ready-to-go-solution?post=472"},{"taxonomy":"qualification","embeddable":true,"href":"https:\/\/eodhd.com\/financial-academy\/wp-json\/wp\/v2\/qualification?post=472"},{"taxonomy":"financial-apis-category","embeddable":true,"href":"https:\/\/eodhd.com\/financial-academy\/wp-json\/wp\/v2\/financial-apis-category?post=472"},{"taxonomy":"financial-apis-manuals","embeddable":true,"href":"https:\/\/eodhd.com\/financial-academy\/wp-json\/wp\/v2\/financial-apis-manuals?post=472"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}