P
📊Analyse de donnéesIntermediateAll AIs

GitHub Copilot Prompt for Analyzing a Survey

Survey analysis is a crucial step for extracting actionable insights from raw data. GitHub Copilot, with its code generation and contextual understanding capabilities, becomes a powerful ally for automating response processing, identifying statistical trends, and producing relevant visualizations. Whether you work with CSV files exported from Google Forms, Typeform, or SurveyMonkey, Copilot can help you quickly write Python or R code to clean data, calculate distributions, perform cross-tabulations, and generate clear charts. Instead of spending hours manually manipulating spreadsheets, you can describe in natural language what you want to analyze and have Copilot generate the corresponding code. This approach is particularly effective for product teams, UX researchers, and marketing managers who need to quickly transform hundreds of responses into concrete recommendations. The prompt below is designed to maximize the relevance of Copilot's suggestions by clearly structuring your analysis expectations.

Paste in your AI

Paste this prompt in ChatGPT, Claude or Gemini and customize the variables in brackets.

Comprehensive survey analysis

Source file: survey_results.csv

Columns: timestamp, age_group, satisfaction (1-5), recommend (yes/no), open_feedback

import pandas as pd
import matplotlib.pyplot as plt
import seaborn as sns

1. Load data and display a statistical summary (number of respondents, completion rate, distribution by age group)

2. Calculate overall average satisfaction score and by demographic segment (age_group)

3. Calculate Net Promoter Score (NPS) from the recommend column

4. Identify correlations between satisfaction and likelihood to recommend

5. Extract recurring themes in open-ended responses (open_feedback) with a keyword frequency count

6. Generate 4 visualizations: satisfaction distribution (histogram), NPS by segment (barplot), word cloud of feedback, correlation matrix

7. Produce an executive summary in markdown with top 5 insights and 3 actionable recommendations

Personalize this prompt with Léa

Answer 3 questions and Léa tailors the prompt to your situation.

Why this prompt works

This prompt works because it provides Copilot with the full dataset context (file name, exact columns, data types) and breaks down the analysis into precise numbered steps. The sequential comment structure guides Copilot to generate code block by block rather than a monolithic response. Including specific metrics (NPS, correlations, text analysis) forces technically relevant suggestions rather than generic code.

Use Cases

Analyze a Survey

Variants

Expected Output

Copilot generates a complete Python script that loads the CSV, produces descriptive statistics by segment, calculates NPS, and creates four professional visualizations using Matplotlib and Seaborn. The script also includes a term frequency analysis of open responses and an executive summary formatted in markdown ready to share with stakeholders.

Frequently Asked Questions

Can GitHub Copilot analyze a CSV file directly without me writing any code?

No, GitHub Copilot does not process data files directly. It works as a coding assistant that generates analysis scripts based on your descriptive comments. You need to open a Python or Jupyter Notebook file in VS Code, describe your analysis in comments, and Copilot will suggest the corresponding code. The advantage is that you get a reproducible pipeline you can re-run with every new batch of responses.

How do I adapt the prompt if my survey uses different scales (7-point Likert, multiple choice, ranking)?

Modify the prompt comments to explicitly specify the type and scale of each question. For example, replace 'satisfaction (1-5)' with 'satisfaction (Likert 1-7)' or 'multiple_choice (values: A, B, C, D)'. The more precise you are about the data structure, the better Copilot will generate suitable code. For multiple-choice questions with comma-separated values in a single cell, add a comment indicating the format: '# favorite_features column: multiple values separated by commas, split using str.split'.

Can Copilot help me analyze open-ended responses from a survey in French?

Yes, but with a few precautions. In your prompt, explicitly state that the texts are in French so Copilot uses the correct stopwords and tokenization parameters. Add a comment like '# Texts in French: use French stopwords from NLTK and spaCy fr_core_news_sm for NLP'. Copilot will then suggest code with the appropriate libraries and language models. For sentiment analysis in French, it will guide you toward models like CamemBERT rather than English-specific tools.

Learn more

Check the full skill on Prompt Guide to master this technique from A to Z.

View on Prompt Guide

📬 Get new prompts every week

Join our newsletter and never miss a prompt.

Similar Prompts

Multichannel marketing data analysis

Complete multichannel marketing performance analysis with ROI calculation, attribution models, and budget optimization.

0229

Choose the right visualization for your data

Guide the choice of optimal chart type based on data, audience, and message to communicate.

0206
📊Analyse de donnéesIntermediateAll AIs

Web analytics metrics analysis

Comprehensive web analytics metrics analysis to understand visitor behavior and identify optimization areas.

0203
📊Analyse de donnéesIntermediateChatGPT

ChatGPT Prompt for Analyzing a Survey

Survey analysis is a crucial step for transforming raw data into actionable insights. Whether you collected responses via Google Forms, Typeform, or any other tool, ChatGPT can help you identify trends, segment respondents, and draw relevant conclusions in minutes. Where an analyst would spend hours cross-referencing variables and writing a report, AI significantly speeds up the process while maintaining methodological rigor. This prompt is designed to guide ChatGPT through a structured analysis of your survey results: synthesis of quantitative data, interpretation of open-ended responses, identification of significant correlations, and formulation of concrete recommendations. It works equally well for a customer satisfaction survey, a market study, or an internal questionnaire. The proposed approach combines descriptive statistical analysis and thematic qualitative analysis, offering you a complete and nuanced view of your results without requiring advanced data science skills.

00