Project Description:
This project provides a comprehensive, data-driven analysis of three critical sectors - Finance, Defense, and Healthcare , under the administrations of President Donald Trump and President Joe Biden administration. By using a robust dataset of 10,542 APIs, this study explores the economic and policy implications of the Trump presidency, particularly in light of his victory in the 2024 U.S. presidential election.
The primary goal of this project is to examine the evolution of the economic and social landscape within these sectors during the Trump and Biden administrations. Through sentiment analysis, data visualization, and comparative analysis of key metrics, the study seeks to uncover insights into how these sectors were shaped by the policies of both administrations.
Sentiment Analysis
The sentiment analysis component focused on social media data relating to the U.S. economy, defense policies, and healthcare employment, spanning the period from July 1 to November 30, 2024. TextBlob, a natural language processing tool, was used to analyze 10,542 APIs, classifying sentiments as positive, negative, or neutral. Additionally, sentiment word clouds were created for each sector to visualize the most frequently used keywords and their emotional connotations.
Sectoral Analysis
Finance: The analysis of public sentiment surrounding Donald Trump aimed to gauge market perceptions during both the Trump and Biden administrations. A comparative study of key economic metrics, including GDP performance and unemployment rates, was conducted to provide insights into economic trends, shifts, and their broader implications under each administration.
Defense: This component analyzed government spending on defense, along with sentiment data surrounding defense policies, while evaluating stock trends for major defense companies. The study specifically focused on defense budgets, identifying fiscal priorities, and contrasting the approaches of the Trump and Biden administrations in this critical area.
Healthcare: Employment trends within the healthcare sector were examined, alongside public sentiment and stock trends for major healthcare companies. This analysis provided valuable insights into the sector’s growth, challenges, and workforce trends, helping to understand the broader impact of administrative policies on the industry.
This project presents a thorough examination of shifts in public sentiment, economic metrics, and policy priorities across two distinct U.S. administrations. The findings provide valuable insights into the influence of both Trump and Biden's policies on the finance, defense, and healthcare sectors, highlighting how their leadership has shaped key aspects of the U.S. economy and society.
Data Collection and Preprocessing
The pie chart illustrates the distribution of 10,542 cleaned records gathered using open-source APIs, including Reddit, NewsAPI, GNews, and NYTimes. The data collection process employed Python libraries such as praw for Reddit and requests for NewsAPI. Keywords like "Trump," "Trump's election impact," "Trump's victory," "post-election financial policies," "economy," "defense," and "healthcare" were utilized to filter data relevant to the project's primary focus areas: Defense (38.4%), Finance (33.0%), and Healthcare (28.6%).
A major challenge during this phase involved cleaning the dataset, particularly in standardizing the date-time format across different APIs, as they operated in varying time zones. Addressing this issue was crucial to maintain consistency and ensure the accuracy of subsequent analyses.
This data collection marks the initial step of the project, which aims to explore the potential impacts of Donald Trump's victory in the 2024 U.S. presidential election. The analysis focuses on trends and sentiments within the economy, defense, and healthcare sectors.
This section provides a detailed analysis of the Finance sector under the Trump and Biden administrations, focusing on key metrics such as GDP growth rate, unemployment rate, and public sentiment. The GDP and unemployment analysis was conducted for the periods corresponding to the Trump administration (2017–2021) and the Biden administration (2021–2024). The sentiment analysis specifically focuses on the time frame of Donald Trump’s recent 2024 presidential election campaign and victory, offering insights into public perceptions during this period.
Trump Administration: The GDP growth rate showed initial stability, followed by a sharp contraction during the COVID-19 pandemic in 2020. However, a strong rebound was observed immediately after.
Biden Administration: The GDP maintained a relatively stable growth trajectory, with an average growth rate higher than during the Trump administration.
Insights:
A time-series analysis reveals significant volatility in GDP growth during Trump’s administration, notably marked by sharp fluctuations.
In contrast, the Biden administration exhibited more stable and consistent GDP growth. On average, the Biden administration achieved higher GDP growth compared to Trump’s tenure.
The unemployment rate is a pivotal economic indicator, reflecting the health of the labor market and broader economic conditions.
Trump Administration:
The average unemployment rate during the Trump administration was 5.04%, with a notable pre-COVID-19 low. However, the COVID-19 pandemic triggered an unprecedented surge in unemployment, peaking at over 14%. This sharp rise in unemployment was a direct consequence of widespread lockdowns and economic disruptions caused by the pandemic. The post-pandemic recovery saw fluctuating unemployment levels as the economy gradually re-opened.
Biden Administration:
Under the Biden administration, the average unemployment rate decreased to 4.12%, reflecting a steady recovery from the pandemic's peak. Key policies, including the Inflation Reduction Act and significant stimulus packages, played a crucial role in supporting job creation and economic recovery. The Biden administration's efforts to stabilize the economy contributed to the consistent decline in unemployment over time.
Insights:
A comparative chart of the unemployment trends under both administrations reveals a clear contrast. The Trump administration's unemployment trajectory was marked by significant volatility, driven largely by the impact of the pandemic. In contrast, the Biden administration exhibited a much more stable and steady decline in unemployment, illustrating the effectiveness of recovery policies and the gradual return of the labor market to pre-pandemic levels.
These insights underscore the differing economic challenges faced by each administration, with the Trump administration navigating a crisis-induced spike in unemployment, while the Biden administration focused on recovery and stabilization.
Sentiment analysis was conducted on 3,482 social media posts collected from platforms such as Reddit ,NewsAPI, Gnews and NYtimes, focusing on public reactions to Trump’s election campaign and victory. The analysis covered the period from July 1 to November 30, 2024.
Findings:
Positive Sentiments: 345 posts (9.91%)
Neutral Sentiments: 460 posts (13.20%)
Negative Sentiments: 102 posts (2.93%)
Average Sentiment Score: 0.07
The positive sentiment toward Trump in 2024, despite the volatility in unemployment and GDP growth during his first term, can be explained through several key factors, particularly how the public and markets interpreted the long-term effects of his policies and leadership. While the data shows volatility in both unemployment and GDP under Trump, there are several reasons why many still viewed him favorably, particularly in the context of the 2024 election:
Trump’s Presidency: The sharp fluctuations in GDP growth and the spike in unemployment during Trump’s term were largely attributed to the unprecedented economic disruptions caused by the COVID-19 pandemic. While these were significant challenges, many people believed that Trump’s administration was effective in managing the initial shock and spearheading the economic reopening.
Sentiment Analysis Insight: Trump's pro-business stance, tax cuts, and deregulatory policies were credited with helping the economy recover more quickly once the pandemic restrictions began to lift. Despite the volatility, many saw Trump's leadership as a driving force behind the early recovery, particularly in the stock market, which was seen as a sign of economic resilience.
Trump’s Presidency: Even with the economic disruptions caused by the pandemic, there was a belief that Trump's policies—especially his tax cuts, deregulation, and focus on bringing jobs back to the U.S.—would result in strong long-term growth once the immediate challenges were overcome.
Sentiment Analysis Insight: Trump’s vision of revitalizing American manufacturing and reducing corporate taxes aligned with expectations of future economic prosperity. Many voters and business owners believed that a second term under Trump would lead to sustained growth and job creation, driving positive sentiment in the finance sector.
Trump’s Presidency: The volatility in economic data, particularly during the pandemic, led many to view Trump's leadership as resilient in the face of unprecedented challenges. His push to reopen businesses and his aggressive economic stimulus measures were seen as contributing to the rapid recovery of the economy.
Sentiment Analysis Insight: Many social media discussions reflected a belief that Trump was capable of managing economic crises effectively. The perception that he could navigate uncertainty and restore the economy to growth helped generate positive sentiment, particularly in the finance sector, which values stability and resilience.
Biden’s Presidency: While Biden’s administration succeeded in stabilizing the economy and reducing unemployment, some critics pointed to slower GDP growth and inflation as signs that recovery policies under Biden were not as effective as they could have been.
Sentiment Analysis Insight: Many believed that Biden’s policies, particularly the expansive government spending in the form of recovery packages, were not as effective at stimulating long-term growth as Trump’s pro-business stance. This perception of slower recovery and the challenges of addressing inflation contributed to a less favorable view of Biden, especially among voters who prioritized economic stability and growth.
Trump’s Economic Legacy: Many voters and financial analysts viewed Trump’s tax cuts, deregulation, and business-focused policies as foundational to the recovery, despite the pandemic’s disruptive impact. The positive sentiment reflected an anticipation that Trump would continue these policies and strengthen the U.S. economy in the long term.
Biden's Economic Legacy: On the other hand, Biden’s policies were seen as more focused on government spending and social welfare, which some in the business community and financial sector viewed as less conducive to rapid economic growth. The higher inflation and the slower recovery from the initial pandemic shock under Biden’s administration led some voters to question the effectiveness of his approach.
A sentiment word cloud was generated to visualize the most frequently mentioned terms in social media posts related to Donald Trump's policies and their impact on the U.S. economy. This analysis focused on finance-related keywords such as "stock market," "inflation," "GDP," and "tax reform," extracted from posts between July 1 and November 30, 2024. Using Python libraries like WordCloud, json, and matplotlib, the text data was filtered, cleaned, and processed to create a word cloud that highlights the key topics in public discourse surrounding Trump’s economic influence.
The sentiment word cloud offers a clear, intuitive way to grasp the recurring themes in conversations about Trump's economic policies. It sheds light on the public's concerns, the focus of political discourse, and the major trends in the financial sector. By visualizing the most frequently mentioned keywords, the word cloud helps identify which economic issues are being debated most, enabling businesses, analysts, and policymakers to better understand public sentiment and refine their strategies.
While the data from unemployment and GDP trends shows volatility under Trump, the sentiment analysis indicates that many viewed Trump as a more favorable candidate for long-term economic prosperity in 2024. This perception was largely shaped by his pro-business policies, such as tax cuts, deregulation, and a focus on job creation, which were expected to result in stronger economic growth once the pandemic-related disruptions were overcome. In contrast, Biden’s more stable but slower economic recovery and concerns over inflation contributed to the view that Trump was the better candidate for driving sustained economic growth and stability.
This report analyzes government spending trends during the Trump administration (2017-2020) and the Biden administration (2021-2023) with a focus on defense spending and its proportion relative to total government expenditures. Additionally, sentiment analysis explores public reaction to Donald Trump’s victory in the 2024 election and its implications for Defense and Security policies.
Insights:
Trump Administration (2017-2020):
Total government spending rose steadily, with a sharp increase in 2019 and 2020, likely influenced by economic stimulus packages and pandemic-related expenditures.
Biden Administration (2021-2023):
Spending plateaued in 2021 and 2022 before showing slight growth in 2023, reflecting a shift toward post-pandemic fiscal stabilization.
Insights:
Trump Administration:
Defense spending increased significantly from approximately $650 billion in 2016 to nearly $800 billion in 2020. This reflects Trump’s emphasis on rebuilding the military and prioritizing national defense.
Biden Administration:
Defense spending continued to grow, reaching around $850 billion by 2023, albeit at a slower rate compared to the Trump years.
3. Percentage of Defense Spending Relative to Total Government Spending:
Insights:
Under Trump, the proportion of defense spending to total government expenditure initially increased, peaking around 10.75% in 2019 before declining.
During Biden’s tenure, the defense-to-total spending ratio hit a low in 2021 but started recovering in subsequent years.
The decline during 2020-2021 is partly attributed to pandemic-related non-defense expenditures overshadowing defense allocations.
As part of my project analyzing public sentiment towards Donald Trump’s re-election and its implications for the defense sector, I conducted a sentiment analysis on social media posts collected from a total of 3,017 APIs. The data spans a comprehensive period, providing insights into the public's perception of defense policies and leadership under Trump’s administration.
Positive Sentiments: 208 posts (6.90%)
Neutral Sentiments: 352 posts (11.67%)
Negative Sentiments: 107 posts (3.55%)
Average Sentiment Score: 0.04
Despite relatively low positive sentiment, the overall average sentiment score indicates a slight positive tilt. Neutral sentiments dominated, reflecting public uncertainty or mixed opinions about Trump’s defense policies.
Trump’s defense policies were viewed as aggressive and direct, focusing on military readiness and global positioning. Many believed his leadership strengthened the U.S. against rising geopolitical challenges.
Sentiment Analysis Insight: Posts reflecting positive sentiments credited Trump’s strong defense posture and his efforts to deter foreign adversaries. His “peace through strength” rhetoric resonated with voters concerned about national security.
Biden’s term emphasized alliances, diplomacy, and modernizing the military through technology. While this was praised in some circles, others criticized it as less assertive compared to Trump’s policies.
Sentiment Analysis Insight: Negative sentiments often stemmed from comparisons with Trump’s more forceful policies, while neutral sentiments reflected a wait-and-see attitude toward Biden’s defense strategies.
A sentiment word cloud was generated to visually represent the most frequently mentioned terms in social media posts discussing Donald Trump’s defense policies and their impact on the U.S. military and national security. This analysis focused on defense-related keywords such as "military spending," "national security," "Space Force," and "global threats," extracted from posts spanning July 1 to November 30, 2024. The text data was meticulously filtered, cleaned, and processed using Python libraries like WordCloud and matplotlib, resulting in a visually rich representation of public discourse.
1. Key Themes:
The word cloud highlights dominant topics, including "military modernization," "cybersecurity," and "global dominance," which reflect the public's focus on Trump’s defense priorities. These terms emphasize significant interest in efforts to strengthen the U.S. military, advance technological capabilities, and maintain global leadership in defense strategies.
2. Policy Figures and Leadership:
Notably, the name "Pete Hegseth" appears prominently in the word cloud, indicating frequent mentions and discussions surrounding his potential nomination as Secretary of Defense under Trump’s leadership. This underscores the critical role of personnel decisions in shaping defense policy narratives and public expectations. Hegseth’s alignment with Trump’s “America First” philosophy further fueled discourse about the direction of Trump’s defense initiatives.
3. Public Concerns and Trends:
Terms like "China," "missile defense," and "alliance" dominate the conversation, reflecting public awareness of and concern about pressing global challenges. Discussions on these topics highlight the importance of international partnerships, geopolitical threats, and the U.S.’s preparedness to navigate complex security landscapes.
While Trump’s defense spending and policies garnered mixed public sentiment, the analysis shows a slightly positive overall perception in 2024. Many appreciated his focus on military strength, national security, and innovative initiatives like the Space Force. However, significant neutral sentiment reflects uncertainty about the long-term impacts of his aggressive spending and leadership style.
In contrast, Biden’s slower defense spending growth and focus on alliances were seen as stabilizing but less impactful in addressing emerging threats. This contrast contributed to Trump being viewed by some as the stronger candidate for ensuring U.S. military dominance in the coming years.
This section provides a detailed analysis of the Healthcare sector under the Trump and Biden administrations, with a focus on key metrics such as healthcare employment trends, policy changes, and public sentiment. The analysis of healthcare employment trends spans the periods corresponding to both administrations, specifically from 2017 to 2021 for Trump and from 2021 to 2024 for Biden. Additionally, sentiment analysis was conducted for Donald Trump's 2024 presidential election campaign and victory, providing valuable insights into public perceptions regarding healthcare policies during this period.
The comparative analysis explores the impact of both administrations on healthcare employment, examining shifts in healthcare job growth, wage changes, and public reactions to key healthcare policies. By comparing the approaches of Trump and Biden to healthcare reform, this section highlights the divergent strategies and their implications for the sector, shedding light on how these policies were perceived by the public.
Ambulatory Health Care Services: During Trump's administration, employment in this sector was notably higher, exceeding 30,000 thousand employees, compared to Biden's administration, which recorded approximately 25,000 thousand.
Hospitals: Trump's term displayed slightly higher employment numbers in hospitals compared to Biden's term, indicating relatively stable trends in this segment.
Nursing and Residential Care Facilities: A decline in employment is evident during Biden's administration compared to Trump’s.
Social Assistance: Trump's administration shows a higher employment count, which decreased during Biden's term.
Ambulatory Health Care Services: Growth during Biden's administration (approx. 4%) significantly outpaced Trump's term (<1%).
Social Assistance: Under Biden, growth exceeded 4%, contrasting with a minimal increase under Trump.
Nursing and Residential Care Facilities: Negative growth was evident under Trump, whereas Biden's administration achieved positive growth.
Hospitals: Marginal growth was observed under both administrations, with Biden slightly outperforming Trump.
While Trump’s administration saw higher absolute employment numbers in healthcare, Biden's term showed stronger growth rates, especially in the Ambulatory Health Care Services and Social Assistance sectors.
Sentiment analysis was conducted on 4043 social media posts collected from platforms such as Reddit ,NewsAPI, Gnews and NYtimes, focusing on public reactions to Trump’s election campaign and victory. The analysis covered the period from July 1 to November 30, 2024.
Findings:
Positive Sentiment: 246 posts (approx. 24%).
Neutral Sentiment: Dominant, with 469 posts (approx. 46%).
Negative Sentiment: 130 posts (approx. 13%).
The sentiment analysis revealed that neutral sentiments dominated public discourse, reflecting widespread uncertainty and mixed opinions about Trump’s healthcare policies. Despite this, a slight positive tilt was observed, with an average sentiment score of 0.05, suggesting modest approval of Trump’s healthcare leadership during his 2024 campaign.
A sentiment word cloud was generated to visually represent the most frequently mentioned terms in social media posts discussing Donald Trump’s healthcare policies and their impact on the U.S. healthcare system. This analysis focused on healthcare-related keywords such as "healthcare reform," "Medicare," "insurance," and "mental health," extracted from posts spanning July 1 to November 30, 2024. The text data was meticulously filtered, cleaned, and processed using Python libraries like WordCloud and matplotlib, resulting in a visually rich representation of public discourse.
Key Themes:
The word cloud highlights dominant topics, including "healthcare access," "Medicare for All," and "insurance costs," reflecting the public’s focus on Trump’s stance on healthcare reform. These terms reveal significant concern about affordability, the future of universal healthcare policies, and the impact of potential policy changes on citizens’ access to healthcare.
Policy Figures and Leadership:
Notably, the name "Jared Isaacman" appears prominently in the word cloud, indicating frequent mentions and discussions surrounding his nomination for NASA under Trump in 2025. His name appears as part of the ongoing discourse on leadership appointments and their potential influence on healthcare policies, especially related to space health initiatives, which could tie into broader healthcare and medical technologies under Trump's administration.
Public Concerns and Trends:
Terms like "mental health," "health insurance," and "affordable care" dominate the conversation, reflecting growing public concern about mental health services and healthcare coverage, particularly as they relate to affordability and quality. The prominence of these terms underscores the significant debate surrounding healthcare reform and the future of healthcare accessibility under Trump’s policies.
Healthcare Employment Under Trump:
The Trump administration emphasized deregulation, fostering private-sector growth, and reducing bureaucratic barriers in healthcare. Policies such as the expansion of association health plans and the rollback of Affordable Care Act (ACA) mandates provided businesses with greater flexibility, indirectly supporting employment stability in healthcare.
Sectors like Ambulatory Health Care Services and Social Assistance experienced higher overall employment during his term, reflecting the administration’s focus on economic growth as a foundation for workforce resilience.
Positive sentiments highlighted Trump’s ability to maintain employment across critical healthcare sectors, crediting his pro-business policies for creating a stable job market. However, concerns about the long-term impact of deregulation on public health and safety tempered some of this approval.
Healthcare Employment Under Biden :
Biden’s administration prioritized expanding Medicaid, strengthening the Affordable Care Act, and increasing federal funding for public health initiatives. These reforms directly addressed healthcare access disparities and emphasized equity-focused policies. Employment growth was particularly strong in Nursing and Residential Care Facilities and Social Assistance, driven by federal investments in eldercare and community health programs.
However, the total employment levels in key sectors like Ambulatory Health Care Services lagged behind those under Trump, reflecting slower recovery in certain private-sector roles.
The comparison of healthcare employment under Trump and Biden highlights the divergent impacts of their policy approaches.
Trump’s pro-business policies and economic recovery agenda resulted in higher overall employment levels across key healthcare sectors. His administration’s focus on deregulation and private-sector flexibility appealed to voters concerned with job stability and economic resilience, contributing to a slight positive sentiment in public discourse.
Biden’s equity-driven healthcare reforms and expansion of public health investments achieved strong sector-specific growth, particularly in community and eldercare roles. However, his administration’s policies faced criticism for slower total job creation, leading to a more cautious public sentiment.
These findings suggest that while Trump’s leadership was perceived as more effective in maintaining workforce stability, Biden’s policies laid the groundwork for long-term structural reforms in the healthcare system. This distinction underscores the tension between immediate job creation and sustainable, equitable growth in the healthcare sector.
The comparative analysis of the Trump 2017 vs. Biden 2021 administrations across the finance, defense, and healthcare sectors reveals distinct leadership approaches, policy priorities, and public perceptions that shaped the current political landscape.
In the finance sector, Trump’s pro-business policies—such as tax cuts, deregulation, and a focus on job creation—were seen as favorable for long-term economic prosperity. While economic volatility marked his tenure, many viewed Trump as the better candidate for fostering sustained economic growth, particularly after the disruptions caused by the pandemic. In contrast, Biden’s recovery was slower, with rising inflation and concerns about economic stability, making him less favored by those seeking quick economic results. Despite this, Biden’s policies did stabilize the economy post-pandemic, focusing on long-term growth, which appeals to those looking for more structural, sustainable recovery.
In defense, Trump’s emphasis on military strength, national security, and aggressive defense spending received significant public support. His bold initiatives, like the establishment of the Space Force, were well-received, although some questioned the long term sustainability of his defense strategies. Biden’s approach, which focused more on rebuilding international alliances and ensuring strategic stability, was seen as less impactful in addressing emerging military threats. As a result, Trump was perceived by some as the stronger candidate for ensuring U.S. military dominance in the future.
Finally, in healthcare, Trump’s policies, which emphasized deregulation and market-driven growth, contributed to higher employment levels in key healthcare sectors. His approach resonated with those who prioritized immediate job creation and economic resilience. On the other hand, Biden’s healthcare reforms, focused on equity and long-term structural investments, created significant growth in community and eldercare roles but were criticized for their slower pace of job creation. This difference highlights the tension between Trump’s focus on short-term workforce stability and Biden’s vision for sustainable, equitable growth in healthcare.
As Trump returns to power, his leadership style—centered around immediate economic recovery, military strength, and business friendly policies that may continue to appeal to voters seeking stability and growth. However, Biden’s focus on structural reforms, social equity, and international cooperation will likely remain influential as the debate over the future of U.S. governance continues. The nation faces a choice between prioritizing immediate outcomes or investing in reforms for a more sustainable future.