Intro to Data Visualization
  • Introduction
  • Getting started
    • Introduction to Pandas
    • Accessing Files on Colab
    • Reviewing Data
      • Understanding type(data) in Pandas
    • Data Types
      • Categorical Data
      • Numeric Data
      • Temporal Data
      • Geographic Data
    • How to Check Data Type
    • Slicing and Subsetting DataFrames
    • Aggregating Data
  • Visualization Types
    • Exploratory Process
    • Explanatory Process
  • data exploration
    • Exploration Overview
    • Exploration with Plotly
      • Exploring Distributions
      • Exploring Relationships
      • Exploring with Regression Plots
      • Exploring Correlations
      • Exploring Categories
      • Exploring Time Series
      • Exploring Stocks with Candlestick
      • Exploring with Facets
      • Exploring with Subplots
    • Exploring with AI
  • Data Explanation
    • Data Explanation with Plotly
      • Using Text
      • Using Annotations
      • Using Color
      • Using Shape
      • Accessibility
      • Using Animations
    • Use Cases
  • Exercises and examples
    • Stock Market
      • Loading Yahoo! Finance Data
      • Use Cases for YF
      • Exploring YF Data
      • Understanding Boeing Data Over Time
      • Polishing the visualization
      • Analyzing with AI
      • Comparisons
    • The Gapminder Dataset
      • Loading the Gapminder Data
      • Use Cases
      • Exploring the Data
      • Exporting a Static Image
Powered by GitBook
On this page
  • Starting with ChatGPT
  • Comparing Line Chart and Bar Chart
  • Reflection
  1. Exercises and examples
  2. Stock Market

Analyzing with AI

PreviousPolishing the visualizationNextComparisons

Last updated 3 months ago

You can use an LLM such as ChatGPT to analyze and understand the stock price visualization. Let's compare the line chart of Boeing stock prices with the bar chart of Boeing stock prices.

Starting with ChatGPT

Go to ChatGPT (chatgpt.com), and enter in the prompt. Make sure that you have your visualization saved in order to upload it to chatgpt.com.

ChatGPT Prompt:

Here is a basic ChatGPT prompt. If you are unhappy with the results, you can try a slightly different prompt.

What are the key takeaways for this visualization?

ChatGPT Response:

The key takeaways from this visualization of Boeing's stock price for 2024 are:

  1. Overall Trend: The stock price generally declined throughout most of 2024, starting above $240 and dropping below $150 at its lowest point.

  2. Early Decline: There was a sharp drop in the stock price early in the year, indicating a significant event or market reaction during that period.

  3. Mid-Year Stability: The price shows some level of stabilization or smaller fluctuations between May and July 2024, hovering around the $180 range.

  4. Late-Year Recovery: Towards the end of the year, the stock price rebounded, rising from below $150 to approximately $180.

  5. Volatility: The line chart shows considerable volatility throughout the year, with frequent ups and downs, indicating an uncertain market environment for Boeing.

This chart is useful for identifying general trends and periods of volatility but does not provide context for specific events affecting the stock price.

Initial Reflection: What are the ways to improve the analysis from ChatGPT?

Initial Reflection: If you are unhappy with the results, you can try a slightly different prompt such as What are the important patterns in this chart? You should try 2-3 different prompts and compare the results until you feel satisifed.

Comparing Line Chart and Bar Chart

Now let's compare the insights for the line chart from the bar chart. Here's the result from the ChatGPT prompt with the bar chart.

ChatGPT Prompt for bar chart

What are the key takeaways for the following visualization?

ChatGPT Response:

The key takeaways from this bar chart of Boeing's stock price in 2024 are as follows:

  1. Overall Decline: Similar to the previous visualization, the stock price shows a downward trend for most of the year, starting near $250 and reaching below $150 before recovering slightly by the end of the year.

  2. Heightened Detail: The bar chart format provides a clear view of daily price variations, making it easier to observe the consistent changes and fluctuations in price across the year.

  3. Volatility Evident: The uneven heights of the bars reflect daily volatility, with some periods showing more drastic fluctuations than others.

  4. Recovery Towards Year-End: As in the line chart, there is a noticeable upward trend starting late in the year, indicating a partial recovery in the stock price.

  5. Visualization Limitation: The bar chart adds visual weight to individual price points, but the large number of bars makes it harder to observe long-term trends compared to the line chart.

This visualization emphasizes daily movements and short-term volatility more than overall trends, making it suitable for detailed analysis of daily stock behavior.

Reflection

Reflect on the following questions:

  • What are the differences between the analysis for the line chart and the bar chart?

  • What chart seems preferred to analyze the daily stock prices for the year?