📈 Data Analysis Prompts
SQL queries, data cleaning, visualization, insights
← All Categories
4 prompts
Analyze Sales Data and Find Insights
Act as a data analyst. I have sales data with columns: Date, Product, Category, Region, Units Sold, Revenue, Cost. Perform analysis: 1) Summary statistics (total revenue, average order value, top products), 2) Trend analysis (monthly revenue trend, seasonality), 3) Pareto analysis (which 20% of products generate 80% of revenue), 4) Regional comparison, 5) Profit margin by category, 6) Anomaly detection (unusual spikes or drops). Provide both the analysis approach and the specific Excel formulas or SQL queries to run.
💡 Start with the big picture, then drill down. Executives want insights, not just numbers.
SQL for Business Intelligence
Write SQL queries for a business intelligence dashboard. Tables: orders, customers, products, categories. Generate queries for: 1) Daily/weekly/monthly revenue with date truncation, 2) Customer cohort analysis (retention by signup month), 3) Product affinity (frequently bought together), 4) Customer lifetime value (CLV), 5) Churn analysis (inactive customers), 6) Year-over-year growth comparison, 7) Moving average of sales (7-day, 30-day). Use window functions where appropriate.
💡 Use CTEs for readability. Break complex queries into logical steps.
Clean and Prepare Dataset - Python
Write Python code to clean and prepare a messy dataset for analysis. Handle: 1) Load from CSV with encoding issues, 2) Identify and report missing values per column, 3) Handle missing data (drop/fill strategy based on column type), 4) Detect and remove outliers using IQR method, 5) Convert data types (dates, numerics, categoricals), 6) Encode categorical variables (one-hot or label), 7) Normalize/standardize numeric features, 8) Generate a data quality report before and after cleaning. Use pandas.
💡 Always create a data profile report first using pandas-profiling or ydata-profiling.
KPI Dashboard Design
Design a KPI dashboard for a [type of business]. Include: 1) Define 8-10 key metrics with formulas for calculation, 2) Specify data source for each metric, 3) Suggest visualization type for each (gauge, line, bar, number), 4) Layout design (what goes where, priority), 5) Filtering options (date range, department, product), 6) Drill-down paths (what detail to show when clicking a metric), 7) Refresh frequency. Follow the principle: answer the 3 most important questions within 5 seconds of looking.
💡 The best dashboards answer one question: Are we on track? Start with that.