ChatGPT for Data Analysis: A Practical Tutorial

You don't need to learn Python to analyse a messy CSV anymore. Here's the ChatGPT workflow we use daily.

By Rayan Imop9 min read
ChatGPT analysing a spreadsheet with a chart output
Drag, drop, ask.

ChatGPT's data-analysis features turn a messy CSV into a chart in minutes. No Python, no Excel formulas — just plain English.

The 4-step workflow

  • Upload the CSV to ChatGPT.
  • Ask it to describe the columns and quality issues.
  • Ask for the specific cut, pivot or chart you need.
  • Export results back to CSV or as a chart image.

Useful prompts

  • 'Clean missing values and explain what you changed.'
  • 'Show me the top 10 customers by revenue this quarter.'
  • 'Group sales by month and visualise as a bar chart.'
  • 'Highlight any anomalies in this dataset.'

Key takeaways

  • ChatGPT can replace 80% of ad-hoc Excel work.
  • Always sanity-check the output against a known number.
  • Use Enterprise plans for sensitive data.

The 10-Minute Audit: Our Daily Data Workflow

In our studio, we stopped using Excel for exploratory data analysis six months ago. The shift wasn't about following a trend; it was about the 45 minutes we saved on every campaign report. When a raw CSV of 50,000 rows from a Meta ad export hits our desk, we don't start by cleaning columns or building pivot tables manully. Instead, we feed the file into ChatGPT's Advanced Data Analysis—formerly Code Interpreter—with a very specific multi-step prompt. We tell the model to first 'describe the schema and identify missing values,' then 'normalize the currency columns,' and finally 'identify the top three outliers in spend versus conversion.' Our team found that by offloading the grunt work of syntax-heavy Python scripts to GPT-4o, we reduced the time from file upload to initial insight by 82%. We no longer get bogged down in VLOOKUP errors or formatting nightmares that used to kill our momentum before lunch.

However, the 'magic' only happens if you treat the AI like a junior analyst who is prone to hallucinating math. We've learned the hard way that you cannot just ask for a final number and trust it. Every time we run a calculation, we demand the tool show its work. We verify the underlying Python code by clicking the 'view analysis' button. In a recent audit of a client's e-commerce sales, ChatGPT miscalculated a weighted average because it ignored a set of null values. Had we not inspected the code, we would have reported a 12% discrepancy in ROI. The real workflow isn't 'upload and pray'; it is a repetitive cycle of prompting, code verification, and iterative questioning that ensures the logic matches the business objective.

Our Core Prompting Framework for CSVs

  • Data Integrity Check: 'List all columns, identify their data types, and check for null values or duplicate entries.'
  • Statistical Baseline: 'Provide a summary table with mean, median, and standard deviation for all numeric columns.'
  • Correlation Discovery: 'Find which features have the strongest correlation with our primary KPI and explain why.'
  • Visual Prototype: 'Create a seaborn heatmap showing the density of transactions over the last 24 months.'

ChatGPT vs. Claude vs. Julius: Choosing Your Engine

We ran a head-to-head test using a messy 12MB customer churn dataset. ChatGPT (GPT-4o) is our daily driver because its sandbox environment is incredibly robust for handling large files and complex libraries like Matplotlib. It processed our file in 14 seconds and generated three distinct graphs without a single error. In comparison, Claude 3.5 Sonnet's Analysis Tool is noticeably better at 'understanding' the business context of the data. While ChatGPT is superior at raw computation and crunching heavy files, Claude writes more insightful summaries that sound like a human strategist rather than a math textbook. When we need a deck for a stakeholder, we often use ChatGPT to do the heavy lifting of the calculations and then move the results to Claude to interpret the 'why' behind the numbers.

Then there is Julius AI, a specialized tool our team uses for high-stakes statistical modeling. While ChatGPT is a generalist, Julius supports more advanced R scripts and specialized regression models that ChatGPT sometimes stumbles over. When we were trying to run a Monte Carlo simulation for a project budget, ChatGPT timing out was a constant frustration. Julius handled the 5,000-iteration simulation in half the time. However, for 90% of our marketing and operations tasks—like analyzing an export from Shopify or a Google Search Console report—ChatGPT remains the most cost-effective and integrated solution. The key is knowing when the dataset is too large or the math is too complex for a general-purpose LLM.

A beautiful chart created from dirty data is just a pretty lie.— Editorial team notebook

The Mistakes We Made So You Don't Have To

Early on, we trusted ChatGPT's ability to read images of charts. This was a massive failure. When we uploaded a screenshot of a competitor's revenue growth, the AI misread the Y-axis by a factor of ten. It didn't account for the 'in thousands' label that was tucked away in the corner. If you are doing data analysis, you must provide the raw data—CSV, XLSX, or JSON. Never rely on the AI's vision capabilities for precise numbers. Another major pitfall is privacy. At our hub, we never upload files containing PII (Personally Identifiable Information). We've established a protocol where we scrub names and emails from the CSV locally before it ever touches the OpenAI servers. It takes an extra three minutes, but it is the only way to operate responsibly.

Finally, we've seen how 'lazy prompting' leads to generic results. If you ask ChatGPT to 'find interesting trends,' it will give you the most obvious, surface-level observations. You have to push it. We now use a technique we call 'Recursive Interrogation.' After the AI gives us an insight, we ask it to 'Argue against this finding using the data' or 'Tell me why this trend might be a seasonal coincidence instead of growth.' This forced skepticism makes the final report much stronger. We once thought we found a massive win in our newsletter conversion rates, but when we forced the AI to look at it from a different angle, we realized it was just a result of a broken tracking link in one of our main campaigns.

Key takeaways

  • Always verify the Python code generated by the tool to ensure the math handles null values correctly.
  • Scrub PII (emails, names, addresses) locally before uploading any data to a public AI model.
  • Use ChatGPT for the heavy computation and Claude for the strategic interpretation of findings.
  • Demand three counter-arguments for every 'trend' the AI identifies to avoid confirmation bias.

About the author

Rayan Imop

Founder & Managing Editor. Rayan tests AI productivity systems with small businesses and editorial teams, then turns the workflows that survive real client work into practical guides. Every article is reviewed by a second editor before it ships. Meet the full team on our about page.

Published June 4, 2026 · Reviewed by Amelia Osei

Sources & further reading

Frequently asked questions

Is this available on free?

Limited data-analysis features are on free; full features on paid plans.

Get the weekly AI productivity briefing

One short email every Sunday. The tools, prompts and workflows that mattered most this week.