# PM Skills Marketplace Data Analytics Capabilities: SQL Generation, Cohort Analysis, and A/B Testing

> Unlock powerful data analytics with PM Skills Marketplace. Easily generate SQL, perform cohort analysis, and conduct A/B tests using simple CLI commands. No coding needed.

- Repository: [Pawel Huryn/pm-skills](https://github.com/phuryn/pm-skills)
- Tags: deep-dive
- Published: 2026-06-21

---

**The PM Skills Marketplace offers three core data analytics capabilities—SQL query generation, cohort and retention analysis, and A/B test statistical analysis—accessible via CLI commands in the `pm-data-analytics` module without requiring manual code writing.**

The `phuryn/pm-skills` repository ships a dedicated `pm-data-analytics` module that enables product managers to transform raw data into actionable insights. These data analytics capabilities are packaged as discrete, production-ready skills, each exposing a specific command interface defined in the repository's skill specifications and command definitions.

## Core Data Analytics Capabilities

The module defines three primary analytics skills, each implemented as a CLI command that can be invoked directly from the toolkit.

### SQL Query Generation

The SQL query generation skill, specified in [`pm-data-analytics/skills/sql-queries/SKILL.md`](https://github.com/phuryn/pm-skills/blob/main/pm-data-analytics/skills/sql-queries/SKILL.md), transforms natural language requests into production-ready SQL for BigQuery, PostgreSQL, MySQL, Snowflake, and other dialects. Users invoke this capability via the `/pm-data-analytics:write-query` command, defined in [`pm-data-analytics/commands/write-query.md`](https://github.com/phuryn/pm-skills/blob/main/pm-data-analytics/commands/write-query.md), which generates optimized queries, explains the underlying logic, and suggests performance tweaks for the target database.

### Cohort & Retention Analysis

For user engagement analysis, the cohort analysis skill defined in [`pm-data-analytics/skills/cohort-analysis/SKILL.md`](https://github.com/phuryn/pm-skills/blob/main/pm-data-analytics/skills/cohort-analysis/SKILL.md) ingests CSV, Excel, or JSON files to compute retention curves and feature adoption trends. Invoked via `/pm-data-analytics:analyze-cohorts` (specified in [`pm-data-analytics/commands/analyze-cohorts.md`](https://github.com/phuryn/pm-skills/blob/main/pm-data-analytics/commands/analyze-cohorts.md)), this capability builds retention heat-maps and line charts while returning Python snippets using `pandas` for reproducible analysis.

### A/B Test Statistical Analysis

The A/B testing skill in [`pm-data-analytics/skills/ab-test-analysis/SKILL.md`](https://github.com/phuryn/pm-skills/blob/main/pm-data-analytics/skills/ab-test-analysis/SKILL.md) performs rigorous statistical significance testing, sample-size validation, and confidence-interval calculations. Using the `/pm-data-analytics:analyze-test` command from [`pm-data-analytics/commands/analyze-test.md`](https://github.com/phuryn/pm-skills/blob/main/pm-data-analytics/commands/analyze-test.md), the tool accepts experiment CSV exports, runs Z-tests or chi-square tests, and produces a decision matrix recommending whether to ship, extend, or stop the experiment.

## Standard Analytics Workflow

All three data analytics capabilities follow a consistent four-step workflow defined in [`pm-data-analytics/README.md`](https://github.com/phuryn/pm-skills/blob/main/pm-data-analytics/README.md):

1. **Data ingestion** – Upload a schema, CSV, Excel, or JSON file to provide the raw dataset.
2. **Contextual clarification** – The tool queries for dialect specifics, time-ranges, or metric definitions.
3. **Automated generation** – The skill produces SQL, Python, or visualization code based on the inputs.
4. **Explanation & iteration** – Output includes plain-language explanations and interactive prompts for refinements.

## Practical Command Examples

The following examples demonstrate how to invoke each analytics capability from the command line.

To generate a BigQuery-compatible SQL query for daily active users:

```bash
/pm-data-analytics:write-query Show me daily active users for the last 30 days, broken down by plan tier

```

This returns a `SELECT` statement with `COUNT(DISTINCT user_id)`, `GROUP BY date, plan_tier`, and commented explanations of each clause.

To analyze cohort retention from a CSV file:

```bash

# Upload `cohort_engagement.csv`

/pm-data-analytics:analyze-cohorts

```

The output includes a retention heat-map (cohort versus weeks), a Python script using `pandas` to compute retention percentages, and an insight summary highlighting any early-churn cohorts.

To evaluate A/B test results and receive a decision recommendation:

```bash

# Upload `experiment_results.csv`

/pm-data-analytics:analyze-test

```

Results include sample-size validation, p-values, lift calculations, 95% confidence intervals, and a decision table (Ship/Extend/Stop) based on guardrail metrics, plus a ready-to-run Python script for reproducibility.

## Implementation Files

The data analytics capabilities are implemented across the following key files in the `phuryn/pm-skills` repository:

- [`pm-data-analytics/README.md`](https://github.com/phuryn/pm-skills/blob/main/pm-data-analytics/README.md) – Module overview and command signatures
- [`pm-data-analytics/skills/sql-queries/SKILL.md`](https://github.com/phuryn/pm-skills/blob/main/pm-data-analytics/skills/sql-queries/SKILL.md) – SQL generation skill specification
- [`pm-data-analytics/skills/cohort-analysis/SKILL.md`](https://github.com/phuryn/pm-skills/blob/main/pm-data-analytics/skills/cohort-analysis/SKILL.md) – Cohort analysis skill specification
- [`pm-data-analytics/skills/ab-test-analysis/SKILL.md`](https://github.com/phuryn/pm-skills/blob/main/pm-data-analytics/skills/ab-test-analysis/SKILL.md) – A/B test analysis skill specification
- [`pm-data-analytics/commands/write-query.md`](https://github.com/phuryn/pm-skills/blob/main/pm-data-analytics/commands/write-query.md) – Command definition for SQL queries
- [`pm-data-analytics/commands/analyze-cohorts.md`](https://github.com/phuryn/pm-skills/blob/main/pm-data-analytics/commands/analyze-cohorts.md) – Command definition for cohort analysis
- [`pm-data-analytics/commands/analyze-test.md`](https://github.com/phuryn/pm-skills/blob/main/pm-data-analytics/commands/analyze-test.md) – Command definition for A/B testing

## Summary

- The **PM Skills Marketplace** provides three specialized data analytics capabilities through the `pm-data-analytics` module.
- **SQL Query Generation** produces optimized queries for multiple database dialects via `/pm-data-analytics:write-query`.
- **Cohort Analysis** computes retention curves and Python visualizations via `/pm-data-analytics:analyze-cohorts`.
- **A/B Test Analysis** delivers statistical significance testing and decision matrices via `/pm-data-analytics:analyze-test`.
- All skills follow a standardized four-step workflow: data ingestion, contextual clarification, automated generation, and explanation with iteration.
- Each capability is defined in dedicated [`SKILL.md`](https://github.com/phuryn/pm-skills/blob/main/SKILL.md) and command definition files within the repository.

## Frequently Asked Questions

### What databases are supported by the SQL query generation skill?

The SQL query generation skill supports BigQuery, PostgreSQL, MySQL, Snowflake, and other major SQL dialects. According to the skill specification in [`pm-data-analytics/skills/sql-queries/SKILL.md`](https://github.com/phuryn/pm-skills/blob/main/pm-data-analytics/skills/sql-queries/SKILL.md), the tool generates dialect-specific optimized queries and includes performance tweak suggestions for the target database.

### Can I export the Python code generated by the cohort analysis tool?

Yes. The `/pm-data-analytics:analyze-cohorts` command returns Python snippets using `pandas` for reproducible analysis. As implemented in [`pm-data-analytics/skills/cohort-analysis/SKILL.md`](https://github.com/phuryn/pm-skills/blob/main/pm-data-analytics/skills/cohort-analysis/SKILL.md), the output includes both visualizations (heat-maps and line charts) and the underlying Python code to compute retention percentages.

### How does the A/B test analysis determine whether to ship or stop an experiment?

The `/pm-data-analytics:analyze-test` command performs sample-size validation, calculates p-values and confidence intervals, and evaluates guardrail metrics. Based on these statistical results, the tool produces a decision matrix recommending "Ship," "Extend," or "Stop," as defined in [`pm-data-analytics/skills/ab-test-analysis/SKILL.md`](https://github.com/phuryn/pm-skills/blob/main/pm-data-analytics/skills/ab-test-analysis/SKILL.md).

### Do I need to write code to use these data analytics capabilities?

No. The `pm-data-analytics` module is designed for product managers to turn raw data into actionable insights without writing code from scratch. While the tools generate SQL and Python code for transparency and reproducibility, users interact with the capabilities through simple CLI commands and file uploads.