
09|Claude Code with Crazyrouter Series 09: Chapter 6: Data Processing and Analysis
09 | Claude Code with Crazyrouter Series 09: Chapter 6: Data Processing and Analysis#
This is the 9th article in the Crazyrouter Claude Code series. This article focuses on “Claude Code with Crazyrouter Series 09: Chapter 6: Data Processing and Analysis,” covering Chapter 6: Data Processing and Analysis, 6.1 Excel Data Processing, and data organization and cleaning.
Unified integration guidance: Claude Code / Anthropic native clients use
ANTHROPIC_BASE_URL=https://cn.crazyrouter.com; OpenAI-compatible SDKs, HTTP requests, and frontend/backend applications usebase_url=https://cn.crazyrouter.com/v1.
What This Article Covers#
- Who this is for: developers who are using Claude Code, planning to integrate domestic models, or want to route team-wide model calls through Crazyrouter.
- What you’ll learn: how to configure environment variables according to the Crazyrouter documentation, organize your workflow, and avoid the
/v1/v1/...issue caused by an incorrect Base URL. - Recommended preparation: first create a separate API Token in the Crazyrouter console, then follow the Claude Code integration documentation to complete the basic setup.
Chapter 6: Data Processing and Analysis#
6.1 Excel Data Processing#
Claude Code can help you process all kinds of Excel data. Whether you need to organize data, standardize formatting, or filter records, it can handle the work efficiently.
Data Organization and Cleaning#
Removing Duplicate Data#
Remove duplicate data from an Excel spreadsheet:
You: Please help me remove duplicate rows from this Excel spreadsheet. (Upload Excel file)
Claude: Duplicate data has been removed:
Processing results
- Original row count: 150 rows
- Duplicate rows removed: 12 rows
- Remaining row count: 138 rows
Duplicate data has been removed, making the dataset cleaner.
Filling Blank Data#
Fill blank cells in an Excel spreadsheet:
You: Please help me fill the blank cells in this Excel spreadsheet with "None". (Upload Excel file)
Claude: Blank cells have been filled:
Processing results
- Original blank cells: 25
- Filled: 25
- Fill content: "None"
All blank cells have been filled with "None".
Removing Empty Rows and Columns#
Remove empty rows and empty columns from an Excel spreadsheet:
You: Please help me remove empty rows and empty columns from this Excel spreadsheet. (Upload Excel file)
Claude: Empty rows and empty columns have been removed:
Processing results
- Empty rows removed: 8 rows
- Empty columns removed: 3 columns
- Retained data: complete
Empty rows and empty columns have been removed, making the spreadsheet cleaner.
Format Standardization#
Standardizing Date Formats#
Standardize the date format in an Excel spreadsheet:
You: Please help me standardize the date format in this Excel spreadsheet to YYYY-MM-DD. (Upload Excel file)
Claude: Date formats have been standardized:
Processing results
- Original date formats: multiple formats, such as 2024/1/5, 2024-1-5, January 5, 2024, and so on
- Standardized format: YYYY-MM-DD (2024-01-05)
- Cells processed: 45
All dates have been standardized to the YYYY-MM-DD format.
Standardizing Number Formats#
Standardize the number format in an Excel spreadsheet:
You: Please help me standardize the amount format in this Excel spreadsheet by keeping two decimal places and adding thousands separators. (Upload Excel file)
Claude: Number formats have been standardized:
Processing results
- Original formats: multiple formats, such as 1200, 1,200, 1200.00, and so on
- Standardized format: 1,200.00 (two decimal places with thousands separators)
- Cells processed: 68
All amounts have been standardized.
Standardizing Text Formats#
Standardize the text format in an Excel spreadsheet:
You: Please help me standardize the text format in this Excel spreadsheet by trimming leading and trailing spaces and converting everything to uppercase. (Upload Excel file)
Claude: Text formats have been standardized:
Processing results
- Processing method: trim leading and trailing spaces, convert everything to uppercase
- Cells processed: 52
All text has been standardized.
Data Filtering#
Filtering by Condition#
Filter data based on conditions:
You: Please help me filter this Excel spreadsheet to find records where sales are greater than 100,000. (Upload Excel file)
Claude: Records matching the condition have been filtered:
Filter condition
- Sales > 100,000
Filter results
| Product Name | Sales | Sales Date | Salesperson |
|---|---|---|---|
| Product A | 150,000 | 45,306 | Zhang San |
| Product B | 120,000 | 45,311 | Li Si |
| Product C | 180,000 | 45,316 | Wang Wu |
| Product D | 135,000 | 45,319 | Zhao Liu |
A total of 4 records were filtered.
Filtering by Date#
Filter data based on a date range:
You: Please help me filter this Excel spreadsheet to find sales records from January 2024. (Upload Excel file)
Claude: Records matching the condition have been filtered:
Filter condition
- Date range: 2024-01-01 to 2024-01-31
Filter results
| Date | Product | Sales | Salesperson |
|---|---|---|---|
| 2024/1/5 | Product A | 1921/11/25 | Zhang San |
| 2024/1/10 | Product B | 1932/11/7 | Li Si |
| 2024/1/15 | Product C | 1941/1/24 | Wang Wu |
| 2024/1/20 | Product A | 1924/8/21 | Zhang San |
| 2024/1/25 | Product B | 1930/2/11 | Li Si |
A total of 5 records were filtered.
Filtering by Text#
Filter data based on text content:
You: Please help me filter this Excel spreadsheet to find records where the salesperson is "Zhang San". (Upload Excel file)
Claude: Records matching the condition have been filtered:
Filter condition
- Salesperson = Zhang San
Filter results
| Date | Product | Sales | Salesperson |
|---|---|---|---|
| 2024/1/5 | Product A | 1921/11/25 | Zhang San |
| 2024/1/12 | Product C | 1949/4/12 | Zhang San |
| 2024/1/20 | Product A | 1924/8/21 | Zhang San |
| 2024/1/28 | Product B | 1938/4/30 | Zhang San |
A total of 4 records were filtered.
Example Use Case#
Case: A Finance Team Organizes Sales Data#
Scenario: A finance team needs to organize sales data by cleaning the data, standardizing formats, and filtering key information.
You: Please help me organize this sales data spreadsheet:
- Remove duplicate rows
- Fill blank cells with "None"
- Standardize the date format to YYYY-MM-DD
- Standardize the amount format to keep two decimal places
- Filter records where sales are greater than 50,000. (Upload Excel file)
Claude: Sales data organization is complete:
- Data cleaning
- Duplicate rows removed: 5 rows
- Blank cells filled: 8 cells (filled with "None")
- Format standardization
- Date format: standardized to YYYY-MM-DD
- Amount format: standardized to keep two decimal places
- Data filtering
Filtered records where sales > 50,000:
| Date | Product Name | Sales | Salesperson | Region |
|---|---|---|---|---|
| 2024/1/5 | Product A | 2077/12/16 | Zhang San | Beijing |
| 2024/1/12 | Product B | 2113/7/21 | Li Si | Shanghai |
| 2024/1/18 | Product C | 2151/11/19 | Wang Wu | Guangzhou |
| 2024/1/25 | Product A | 2132/9/19 | Zhang San | Beijing |
| 2024/1/30 | Product D | 2187/6/23 | Zhao Liu | Shenzhen |
A total of 5 records were filtered.
- Data analysis
- Total sales: 425,000.00 yuan
- Average sales: 85,000.00 yuan
- Highest sales: 105,000.00 yuan (Product D)
- Lowest sales: 65,000.00 yuan (Product A)
- Salesperson ranking
- Zhang San: 150,000.00 yuan
- Li Si: 78,000.00 yuan
- Wang Wu: 92,000.00 yuan
- Zhao Liu: 105,000.00 yuan
The sales data has been organized and is ready to use for report creation.
Tips#
- Back up your data: Always back up the original data before processing it
- Process step by step: For complex data processing, break it into steps and verify the results at each step
- Use filters: Filter out the data you need to process first, then process it for better efficiency
- Document the process: Record each processing step so you can trace and review it later
- Validate the results: After processing, verify the accuracy and completeness of the data
- Save processing rules: For frequently used data processing rules, save them so you can reuse them next time
Now, try asking Claude Code to help you process some Excel data!
6.2 Data Statistics and Analysis#
Claude Code can help you perform in-depth statistics and analysis on your data, uncover patterns and insights, and support decision-making.
Generate Statistical Results#
Basic Statistics#
Generate basic statistical information for the data:
You: Please help me generate statistical results for this sales data (upload Excel file)
Claude: Basic statistical results have been generated:
Overall statistics
- Number of data rows: 100 rows
- Total sales: 1,234,567 yuan
- Average sales: 12,345.67 yuan
- Highest sales: 50,000 yuan
- Lowest sales: 1,000 yuan
- Median: 10,500 yuan
- Standard deviation: 8,234.56 yuan
Statistics by product
| Product Name | Sales | Share | Average Unit Price |
|---|---|---|---|
| Product A | 400,000 | 0 | 10,000 |
| Product B | 350,000 | 0 | 8,750 |
| Product C | 300,000 | 0 | 7,500 |
| Product D | 184,567 | 0 | 9,228 |
Statistics by region
| Region | Sales | Share |
|---|---|---|
| Beijing | 400,000 | 0 |
| Shanghai | 350,000 | 0 |
| Guangzhou | 300,000 | 0 |
| Shenzhen | 184,567 | 0 |
Frequency Statistics#
Count how often each value appears in the data:
You: Please help me count the number of customers in each region in this customer data (upload Excel file)
Claude: Regional customer frequency statistics have been generated:
Customer count by region
| Region | Customer Count | Share |
|---|---|---|
| Beijing | 3500% | 35% |
| Shanghai | 2800% | 28% |
| Guangzhou | 2200% | 22% |
| Shenzhen | 1500% | 15% |
Analysis conclusions
- Beijing has the most customers, accounting for 35%
- Shanghai comes next, accounting for 28%
- Guangzhou and Shenzhen have relatively fewer customers
Percentage Statistics#
Calculate the percentage distribution of the data:
You: Please help me calculate each product's share of sales in this sales data (upload Excel file)
Claude: Sales shares have been calculated:
Product sales share
| Product Name | Sales | Share |
|---|---|---|
| Product A | 500,000 | 0 |
| Product B | 350,000 | 0 |
| Product C | 250,000 | 0 |
| Product D | 134,567 | 0 |
Analysis conclusions
- Product A is the flagship product, accounting for more than 40%
- Product A and Product B together account for nearly 70%
- Product D has a relatively small share and could be considered for optimization or discontinuation
Analyze Data Trends#
Time Trend Analysis#
Analyze how the data changes over time:
You: Please help me analyze the time trend in this sales data (upload Excel file)
Claude: Time trend analysis has been completed:
Monthly sales trend
| Month | Sales | Month-over-Month Growth |
|---|---|---|
| January | 80,000 | - |
| February | 95,000 | 0 |
| March | 110,000 | 0 |
| April | 105,000 | -0 |
| May | 120,000 | 0 |
| June | 135,000 | 0 |
Trend analysis
- Overall trend: Sales are trending upward, growing from 80,000 yuan in January to 135,000 yuan in June
- Growth: Cumulative growth over 6 months is 68.8%
- Fluctuation: There was a slight decline in April (-4.5%), followed by a return to growth
- Average growth: The average monthly growth rate is about 11.5%
Forecast
If the current growth trend continues, July sales are expected to reach around 150,000 yuan.
Seasonality Analysis#
Analyze seasonal patterns in the data:
You: Please help me analyze the seasonality in this sales data (upload Excel file)
Claude: Seasonality analysis has been completed:
Quarterly sales data
| Quarter | Sales | Share |
|---|---|---|
| Q1 | 285,000 | 0 |
| Q2 | 360,000 | 0 |
| Q3 | 320,000 | 0 |
| Q4 | 269,567 | 0 |
Seasonality analysis
- Peak season: Q2 is the peak sales season, accounting for 29.2%
- Off season: Q4 is the off season for sales, accounting for 21.8%
- Seasonal difference: The peak season is 7.4 percentage points higher than the off season
- Pattern summary: Sales in the first half of the year are better than in the second half, with Q2 reaching the peak
Recommendations
- Increase inventory before the peak season to ensure sufficient supply
- Strengthen promotions during the off season to improve sales performance
Year-over-Year and Month-over-Month Analysis#
Analyze year-over-year and month-over-month changes in the data:
You: Please help me analyze the year-over-year and month-over-month changes in this sales data (upload Excel file)
Claude: Year-over-year and month-over-month analysis has been completed:
Sales data year-over-year and month-over-month analysis
| Month | 2023 Sales | 2024 Sales | YoY Growth | MoM Growth |
|---|---|---|---|---|
| January | 70,000 | 80,000 | 0 | - |
| February | 80,000 | 95,000 | 0 | 0 |
| March | 90,000 | 110,000 | 0 | 0 |
| April | 95,000 | 105,000 | 0 | -0 |
| May | 100,000 | 120,000 | 0 | 0 |
| June | 110,000 | 135,000 | 0 | 0 |
Analysis conclusions
- YoY growth: All months achieved year-over-year growth, with an average growth rate of 18.1%
- MoM growth: Except for April, all other months achieved month-over-month growth
- Growth trend: Overall, the data shows steady growth
- Best performance: June performed best, with year-over-year growth of 22.7%
Discover Data Insights#
Outlier Detection#
Detect outliers in the data:
You: Please help me detect outliers in this sales data (upload Excel file)
Claude: Outliers have been detected:
Outlier detection results
- Detection method: 3σ rule (outside the mean ± 3 standard deviations)
- Mean: 12,345.67 yuan
- Standard deviation: 8,234.56 yuan
- Upper limit: 37,049.35 yuan
- Lower limit: -12,358.01 yuan
Outlier list
| Date | Product | Sales | Outlier Reason |
|---|---|---|---|
| 2024/3/15 | Product A | 2036/11/21 | Exceeds upper limit |
| 2024/5/20 | Product B | 2031/6/1 | Exceeds upper limit |
Analysis recommendations
- Verify the authenticity of these two sales records
- Check whether there were data entry errors
- If they are real sales, analyze the reasons for their success and summarize the learnings
Correlation Analysis#
Analyze correlations between data points:
You: Please help me analyze the correlation between ad spend and sales in this data (upload Excel file)
Claude: Correlation analysis has been completed:
Correlation analysis results
- Correlation coefficient: 0.85
- Correlation strength: Strong positive correlation
- P-value: < 0.01 (significance level)
Analysis conclusion
There is a strong positive correlation between ad spend and sales (correlation coefficient 0.85), indicating that ad spend has a significant impact on sales.
Regression analysis
- Regression equation: Sales = 2.5 × Ad Spend + 10,000
- R² = 0.72 (good fit)
Recommendations
- Continue maintaining ad spend to sustain sales growth
- Optimize the ad delivery strategy to improve ad efficiency
- Monitor the return on ad spend to ensure a reasonable input-output ratio
Cluster Analysis#
Perform cluster analysis on the data:
You: Please help me perform cluster analysis on this customer data and divide customers into three groups: high-value, mid-value, and low-value (upload Excel file)
Claude: Customer cluster analysis has been completed:
Cluster analysis results
High-value customers (20 people)
- Characteristics: Annual spending > 50,000 yuan
- Total spending: 1,200,000 yuan
- Average spending: 60,000 yuan
- Share of total spending: 60%
Mid-value customers (30 people)
- Characteristics: Annual spending 20,000 - 50,000 yuan
- Total spending: 600,000 yuan
- Average spending: 20,000 yuan
- Share of total spending: 30%
Low-value customers (50 people)
- Characteristics: Annual spending < 20,000 yuan
- Total spending: 200,000 yuan
- Average spending: 4,000 yuan
- Share of total spending: 10% Marketing recommendations
- High-value customers: provide dedicated services, follow up regularly, and maintain relationships
- Mid-value customers: offer promotions, increase spending, and convert them into high-value customers
- Low-value customers: offer entry-level products and help them build purchasing habits
Case examples#
Case: Marketing staff analyzing customer data#
Scenario: Marketing staff need to analyze customer data, understand customer characteristics, and develop marketing strategies.
You: Please help me analyze this customer data and provide marketing recommendations (upload an Excel file)
Claude: Customer data analysis completed:
Customer Data Analysis Report
I. Customer overview#
- Total customers: 500
- Total spending: 5,000,000 yuan
- Average spending: 10,000 yuan
- Median spending: 8,000 yuan
II. Customer profile#
- Regional distribution
| Region | Customers | Share | Average spending |
|---|---|---|---|
| Beijing | 15000% | 30% | 1200000% |
| Shanghai | 12500% | 25% | 1100000% |
| Guangzhou | 10000% | 20% | 900000% |
| Shenzhen | 7500% | 15% | 800000% |
| Other | 5000% | 10% | 700000% |
- Age distribution
| Age group | Customers | Share | Average spending |
|---|---|---|---|
| 18-25 | 10000% | 20% | 600000% |
| 26-35 | 20000% | 40% | 1200000% |
| 36-45 | 15000% | 30% | 1100000% |
| 46 and above | 5000% | 10% | 800000% |
- Gender distribution
| Gender | Customers | Share | Average spending |
|---|---|---|---|
| Male | 28000% | 56% | 1100000% |
| Female | 22000% | 44% | 900000% |
III. Consumption behavior analysis#
- Purchase frequency
- High-frequency customers (>10 times/year): 50 customers, 10%, average spending 20,000 yuan
- Medium-frequency customers (5-10 times/year): 150 customers, 30%, average spending 12,000 yuan
- Low-frequency customers (<5 times/year): 300 customers, 60%, average spending 6,000 yuan
- Purchase preferences
- Product A: 300 purchasers, 60%
- Product B: 250 purchasers, 50%
- Product C: 200 purchasers, 40%
- Product D: 150 purchasers, 30%
IV. Customer value analysis#
Customer segmentation
| Segment | Customers | Share | Total spending | Average spending |
|---|---|---|---|---|
| VIP customers | 5000% | 10% | 150000000% | 3000000% |
| Key customers | 10000% | 20% | 150000000% | 1500000% |
| Regular customers | 20000% | 40% | 150000000% | 750000% |
| Potential customers | 15000% | 30% | 50000000% | 333300% |
V. Marketing recommendations#
- VIP customer retention
- Provide dedicated customer support and one-on-one service
- Send gifts and coupons regularly
- Invite them to premium events
- Offer priority access to new products
- Key customer growth
- Provide personalized recommendations
- Send regular care messages
- Offer upgrade discounts to convert them into VIP customers
- Build customer communities to increase stickiness
- Regular customer activation
- Send promotional messages to stimulate purchases
- Recommend suitable product bundles
- Offer first-purchase discounts
- Encourage higher purchase frequency
- Potential customer development
- Send starter gift packs to lower the barrier to trial
- Offer product trial opportunities
- Strengthen brand promotion to improve awareness
- Acquire customers through social media
- Regional strategy
- Focus on developing the Beijing and Shanghai markets (high-spending regions)
- Strengthen penetration in the Guangzhou and Shenzhen markets
- Use online marketing as the main approach for other regions
- Age strategy
- Customers aged 26-45 are the core customer group and should be prioritized for retention
- Customers aged 18-25 are potential customers and should be nurtured
- For customers aged 46 and above, provide age-friendly services
Tips#
- Define the analysis goal: know exactly what you want to analyze and what outcome you want to achieve
- Choose the right analysis method: select an appropriate method based on the data type and analysis goal
- Visualize the results: present analysis results with charts so they are easier to understand at a glance
- Combine with business context: ground the analysis results in real business conditions and avoid impractical conclusions
- Provide actionable recommendations: don't just identify problems; propose feasible solutions
- Track continuously: monitor analysis results regularly and validate whether the recommendations are effective
Now, try asking Claude Code to help you analyze some data!
6.3 Chart and report generation#
Claude Code can help you generate various data charts and professional analysis reports, making data visual and analysis results easier to understand.
Generating data charts#
Bar charts#
Generate a bar chart to compare data:
You: Please help me generate a bar chart comparing the sales revenue of each product (upload an Excel file)
Claude: Bar chart generated:
Product Sales Revenue Comparison Bar Chart
Sales revenue (yuan)
500,000 | ■■■■■
400,000 | ■■■■
300,000 | ■■■
200,000 | ■■
100,000 | ■
+-------------------
Product A Product B Product C Product D
Data notes
- Product A: 500,000 yuan
- Product B: 400,000 yuan
- Product C: 300,000 yuan
- Product D: 200,000 yuan
Analysis conclusion
Product A has the highest sales revenue, 2.5 times that of Product D.
Line charts#
Generate a line chart to show data trends:
You: Please help me generate a line chart showing the time trend of sales revenue (upload an Excel file)
Claude: Line chart generated:
Sales Revenue Time Trend Line Chart
Sales revenue (yuan)
150,000 | *
120,000 | * *
90,000 | * * *
60,000 | * * *
30,000 | * * *
+-------------------
Jan Feb Mar Apr May Jun
Data notes
- January: 80,000 yuan
- February: 95,000 yuan
- March: 110,000 yuan
- April: 105,000 yuan
- May: 120,000 yuan
- June: 135,000 yuan
Analysis conclusion
The overall trend is upward, with cumulative growth of 68.8% over six months.
Pie charts#
Generate a pie chart to show data proportions:
You: Please help me generate a pie chart showing the sales revenue share by region (upload an Excel file)
Claude: Pie chart generated:
Sales Revenue Share by Region Pie Chart
Beijing 32.4%
■■■■■■■
■■■■■■■■■■■■■■■■
■■■■■■■■■■■■■■■■■■■
■■■■■■■■■■■■■■■■■■■■■■
■■■■■■■■■■■■■■■■■■■■■■■■
■■■■■■■■■■■■■■■■■■■■■■■■
■■■■■■■■■■■■■■■■■■■■■
■■■■■■■■■■■■■■■■■■
■■■■■■■■■■■■■■■
Shanghai 28.4%
Guangzhou 24.3%
Shenzhen 14.9%
Data notes
- Beijing: 32.4%
- Shanghai: 28.4%
- Guangzhou: 24.3%
- Shenzhen: 14.9%
Analysis conclusion
Beijing has the highest share of sales revenue, while Shenzhen has the lowest.
Writing analysis reports#
Sales analysis report#
Generate a professional sales analysis report:
You: Please help me write a monthly sales analysis report based on this sales data (upload an Excel file)
Claude: Monthly sales analysis report generated:
January 2024 Sales Analysis Report
I. Overall overview#
This month's sales performance was strong, and all metrics met the expected targets.
Key metrics
- Total sales revenue: 1,234,567 yuan
- Target completion rate: 102.9%
- Year-over-year growth: 15.3%
- Month-over-month growth: 8.7%
II. Sales details#
- By product category
| Product name | Sales revenue | Share | Year-over-year growth |
|---|---|---|---|
| Product A | 500,000 | 0 | 0 |
| Product B | 350,000 | 0 | 0 |
| Product C | 250,000 | 0 | 0 |
| Product D | 134,567 | 0 | 0 |
| Analysis: |
- Product A continues to be the main contributor, accounting for more than 40%
- Product C grew the fastest, with a year-over-year increase of 20.1%
- Product D grew relatively slowly and needs attention
- By region
| Region | Sales | Share | YoY growth |
|---|---|---|---|
| Beijing | 400,000 | 0 | 0 |
| Shanghai | 350,000 | 0 | 0 |
| Guangzhou | 300,000 | 0 | 0 |
| Shenzhen | 184,567 | 0 | 0 |
Analysis:
- Beijing performed best, with a year-over-year increase of 18.5%
- Shenzhen grew relatively slowly, and marketing efforts should be strengthened
- By salesperson
| Salesperson | Sales | Share | YoY growth |
|---|---|---|---|
| Zhang San | 450,000 | 0 | 0 |
| Li Si | 380,000 | 0 | 0 |
| Wang Wu | 280,000 | 0 | 0 |
| Zhao Liu | 124,567 | 0 | 0 |
Analysis:
- Zhang San performed particularly well, accounting for 36.5% of sales
- Zhao Liu needs additional training and guidance
III. Highlights and issues#
Highlights
- Overall sales exceeded the target, with a completion rate of 102.9%
- Product C grew rapidly and became a new growth driver
- Beijing performed strongly, with a year-over-year increase of 18.5%
- Zhang San delivered outstanding sales performance, with a year-over-year increase of 22.1%
Issues
- Product D grew slowly, with only 5.6% growth
- Shenzhen showed weak growth, with a year-over-year increase of 8.7%
- Zhao Liu’s performance was below expectations and needs attention
IV. Plan for next month#
- Sales targets
- Total sales target: 1,350,000 yuan
- Growth target: 9.4% month-over-month growth
- Key actions
- Strengthen marketing for Product D
- Increase market investment in Shenzhen
- Provide dedicated training for Zhao Liu
- Optimize the sales strategy to improve overall performance
V. Risk warnings#
- Intensifying market competition may affect sales growth
- Weak economic conditions in some regions may affect consumption
- Product D is not competitive enough and needs improvement
VI. Summary#
This month’s sales performance was strong, and all key indicators met expectations. However, there is still room for improvement, especially for Product D and the Shenzhen region. Next month, the team will continue working hard to achieve better results.
Customer analysis report#
Generate a professional customer analysis report:
You: Please help me write a customer analysis report based on this customer data (upload an Excel file)
Claude: Customer analysis report generated:
Customer analysis report
I. Customer overview#
As of January 2024, the company had 500 customers. The customer structure is balanced, and value contribution is stable.
Key metrics
- Total customers: 500
- Total spending: 5,000,000 yuan
- Average spending: 10,000 yuan
- Customer retention rate: 85%
II. Customer segmentation#
- VIP customers (50 customers, 10%)
- Characteristics: annual spending > 50,000 yuan
- Total spending: 1,500,000 yuan
- Average spending: 30,000 yuan
- Share of total spending: 30%
Analysis:
Although VIP customers are few in number, they contribute 30% of total spending and are the company’s core customer group.
- Key customers (100 customers, 20%)
- Characteristics: annual spending of 20,000–50,000 yuan
- Total spending: 1,500,000 yuan
- Average spending: 15,000 yuan
- Share of total spending: 30%
Analysis:
Key customers are one of the company’s main customer groups and have the potential to convert into VIP customers.
- Regular customers (200 customers, 40%)
- Characteristics: annual spending of 5,000–20,000 yuan
- Total spending: 1,500,000 yuan
- Average spending: 7,500 yuan
- Share of total spending: 30%
Analysis:
Regular customers make up the largest group and form the company’s foundational customer base.
- Potential customers (150 customers, 30%)
- Characteristics: annual spending < 5,000 yuan
- Total spending: 500,000 yuan
- Average spending: 3,333 yuan
- Share of total spending: 10%
Analysis:
Potential customers currently have limited spending capacity, but there is room for growth.
III. Customer characteristics#
- Regional distribution
- Beijing: 150 customers (30%), average spending 12,000 yuan
- Shanghai: 125 customers (25%), average spending 11,000 yuan
- Guangzhou: 100 customers (20%), average spending 9,000 yuan
- Shenzhen: 75 customers (15%), average spending 8,000 yuan
- Other: 50 customers (10%), average spending 7,000 yuan
- Age distribution
- Ages 18–25: 100 customers (20%), average spending 6,000 yuan
- Ages 26–35: 200 customers (40%), average spending 12,000 yuan
- Ages 36–45: 150 customers (30%), average spending 11,000 yuan
- Ages 46 and above: 50 customers (10%), average spending 8,000 yuan
- Gender distribution
- Male: 280 customers (56%), average spending 11,000 yuan
- Female: 220 customers (44%), average spending 9,000 yuan
IV. Customer behavior#
- Purchase frequency
- High-frequency customers (>10 times/year): 50 customers, 10%
- Medium-frequency customers (5–10 times/year): 150 customers, 30%
- Low-frequency customers (<5 times/year): 300 customers, 60%
- Purchase preferences
- Product A: 300 buyers, 60%
- Product B: 250 buyers, 50%
- Product C: 200 buyers, 40%
- Product D: 150 buyers, 30%
V. Marketing recommendations#
- VIP customer retention
- Provide exclusive service and one-on-one customer support
- Regularly send gifts and coupons
- Invite them to premium events
- Offer early access to new products
- Key customer growth
- Provide personalized recommendations
- Send regular care and engagement messages
- Offer upgrade incentives to convert them into VIP customers
- Build customer communities to increase stickiness
- Regular customer activation
- Send promotional messages to stimulate spending
- Recommend suitable product bundles
- Offer first-purchase discounts
- Encourage more frequent purchases
- Potential customer development
- Send starter packages to lower the barrier to trial
- Offer product trial opportunities
- Strengthen brand promotion to improve awareness
- Acquire customers through social media
VI. Summary#
The company’s customer structure is balanced, with an even distribution across customer tiers. Next month, the team will focus on retaining VIP customers, growing key customers, activating regular customers, and developing potential customers to comprehensively improve customer value.
Example cases#
Case: Finance staff generate a monthly report#
Scenario: Finance staff need to generate a monthly report based on sales data, including charts and analysis.
You: Please help me generate a monthly report based on this sales data, including charts and analysis (upload an Excel file)
Claude: Monthly report generated:
January 2024 sales monthly report
I. Sales overview#
Key metrics
- Total sales: 1,234,567 yuan
- Target completion rate: 102.9%
- Year-over-year growth: 15.3%
- Month-over-month growth: 8.7%
II. Sales trend chart#
Sales (yuan)
150,000 | *
120,000 | * *
90,000 | * * *
60,000 | * * *
30,000 | * * *
+-------------------
Jan Feb Mar Apr May Jun
III. Product sales comparison#
Bar chart comparing product sales
Sales (yuan)
500,000 | ■■■■■
400,000 | ■■■■
300,000 | ■■■
200,000 | ■■
100,000 | ■
+-------------------
Product A Product B Product C Product D
Product sales details table
| Product name | Sales | Share | YoY growth |
|---|---|---|---|
| Product A | 500,000 | 0 | 0 |
| Product B | 350,000 | 0 | 0 |
| Product C | 250,000 | 0 | 0 |
| Product D | 134,567 | 0 | 0 |
IV. Regional sales distribution#
Pie chart of each region’s sales share
Beijing 32.4%
■■■■■■■
■■■■■■■■■■■■■■■■
■■■■■■■■■■■■■■■■■■■
■■■■■■■■■■■■■■■■■■■■■■
■■■■■■■■■■■■■■■■■■■■■■■■
■■■■■■■■■■■■■■■■■■■■■■■■
■■■■■■■■■■■■■■■■■■■■■
■■■■■■■■■■■■■■■■■■
■■■■■■■■■■■■■■■
Shanghai 28.4%
Guangzhou 24.3%
Shenzhen 14.9%
Regional Sales Details
| Region | Sales | Share | YoY Growth |
|---|---|---|---|
| Beijing | 400,000 | 0 | 0 |
| Shanghai | 350,000 | 0 | 0 |
| Guangzhou | 300,000 | 0 | 0 |
| Shenzhen | 184,567 | 0 | 0 |
V. Salesperson Performance Ranking#
| Rank | Salesperson | Sales | Share | YoY Growth |
|---|---|---|---|---|
| 1 | Zhang San | 450,000 | 0 | 0 |
| 2 | Li Si | 380,000 | 0 | 0 |
| 3 | Wang Wu | 280,000 | 0 | 0 |
| 4 | Zhao Liu | 124,567 | 0 | 0 |
VI. Highlights and Issues#
Highlights
- Overall sales exceeded the target, with a completion rate of 102.9%
- Product C grew rapidly, up 20.1% year over year
- Beijing performed strongly, up 18.5% year over year
- Zhang San delivered outstanding sales performance, up 22.1% year over year
Issues
- Product D grew slowly, up only 5.6%
- Growth in Shenzhen was weak, up 8.7% year over year
- Zhao Liu's performance was below expectations and needs attention
VII. Plan for Next Month#
Sales Targets
- Total sales target: 1,350,000 yuan
- Growth target: 9.4% month-over-month growth
Key Actions
- Strengthen marketing for Product D
- Increase market investment in Shenzhen
- Provide targeted training for Zhao Liu
- Optimize sales strategies to improve overall performance
VIII. Risk Notes#
- Intensifying market competition may affect sales growth
- Weak economic conditions in some regions may affect consumption
- Product D lacks sufficient competitiveness and needs improvement
Tips#
- Choose the right chart type: select the most suitable chart type based on the data characteristics
- Keep charts simple and clear: avoid excessive decoration and highlight the data itself
- Keep the report structure clear: use clear headings and hierarchy
- Keep the data accurate: make sure the data in the report is correct
- Go deep in the analysis: don't just show the data; provide deeper analysis and insights
- Make recommendations actionable: keep your recommendations specific and executable
Now, try asking Claude Code to help you generate some charts and reports!
Related Reading#
- Previous article: Article 08
- Next article: Article 10
- Configuration docs: Connect Claude Code to Crazyrouter
- API address guide: Base URL and
/v1usage - One-click configuration script: Crazyrouter Claude Code one-click configuration script
Start Connecting to Crazyrouter#
If you're ready to connect Claude Code, domestic models, or your own applications to Crazyrouter through a unified setup, follow this sequence:
- Go to the Crazyrouter console, create a dedicated API Token, and manage permissions separately by project or team.
- Use the root domain for Claude Code:
https://cn.crazyrouter.com; usehttps://cn.crazyrouter.com/v1for OpenAI-compatible SDKs. - When you need to automatically check the environment or quickly write configuration, use the Crazyrouter Claude Code one-click configuration script.
- If debugging fails, check the console logs first, then verify the API Endpoint guide. Pay special attention to whether the Base URL has an extra
/v1.
When you need to evaluate model costs or choose different models, check the Crazyrouter pricing and models page first, then add your commonly used models to the Token whitelist.





