Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
beita6969 avatar

Social Science Analysis

  • 16 installs
  • 869 repo stars
  • Updated June 8, 2026
  • beita6969/scienceclaw

social-science-analysis is a Claude skill covering social science research methods including survey design, psychometrics, qualitative analysis, content analysis, and network analysis.

About

This skill provides social science research methods including survey design, qualitative analysis, content analysis, network analysis, psychometrics, and mixed methods. A researcher uses it to design surveys, build and validate scales, code interviews, run factor analysis or SEM, and analyze social networks. It supplies Python code for reliability, factor analysis, content analysis, inter-coder reliability, and centrality measures across sociology, psychology, political science, education, and communication.

  • Covers survey design, psychometrics, qualitative coding, content analysis, and network analysis
  • Python snippets for Cronbach's alpha, factor analysis, SEM (semopy), and Cohen's kappa
  • Braun and Clarke thematic analysis and grounded-theory coding workflows

Social Science Analysis by the numbers

  • 16 all-time installs (skills.sh)
  • Ranked #1,318 of 2,065 Data Science & ML skills by installs in the Skillselion catalog
  • Data as of Aug 2, 2026 (Skillselion catalog sync)
At a glance

social-science-analysis capabilities & compatibility

Capabilities
data analysis · research
Use cases
data analysis · research
From the docs

What social-science-analysis says it does

Social science research methods including survey design, qualitative analysis, content analysis, network analysis, psychometrics, and mixed methods.
SKILL.md
Thematic Analysis (Braun & Clarke)
SKILL.md
Calculate Cronbach's alpha for scale reliability
SKILL.md
npx skills add https://github.com/beita6969/scienceclaw --skill social-science-analysis

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs16
repo stars869
Last updatedJune 8, 2026
Repositorybeita6969/scienceclaw

What it does

Design surveys, build psychometric scales, code qualitative data, or run content and network analysis for social science.

Who is it for?

Designing surveys, building scales, coding qualitative data, and running content or network analysis in the social sciences.

Skip if: Pure natural-science or clinical-trial data analysis.

When should I use this skill?

You are designing a survey, validating a scale, coding qualitative data, or running content or network analysis.

What you get

Validated scales, reliably coded qualitative data, and correctly specified factor, content, and network analyses.

  • survey design
  • validated scale
  • coding framework

By the numbers

  • 6-step Braun and Clarke thematic analysis
  • 6 sampling methods compared
  • Likert scales of 5 or 7 points

Files

SKILL.mdMarkdownGitHub ↗

Social Science Analysis

Research methods for social and behavioral sciences. Venv: source /Users/zhangmingda/clawd/.venv/bin/activate

Survey Design

Question Types & Best Practices

  • Closed-ended: Likert scales, multiple choice, ranking
  • Open-ended: Free text (harder to analyze, richer data)
  • Matrix questions: Multiple items, same scale (efficient but watch for straight-lining)

Likert Scale Design

Strongly Disagree (1) — Disagree (2) — Neutral (3) — Agree (4) — Strongly Agree (5)
  • Use 5 or 7 points (odd for neutral option)
  • Mix positively and negatively worded items (reverse-code in analysis)
  • Avoid double-barreled questions
  • Pilot test with 10-20 respondents

Sampling Methods

MethodWhenProsCons
Simple randomKnown populationUnbiasedNeed sampling frame
StratifiedSubgroup comparisonPrecise estimates per stratumComplex
ClusterGeographic spreadCost-effectiveHigher design effect
ConvenienceExploratoryEasyNot generalizable
SnowballHard-to-reach populationsAccess hidden groupsSelection bias
QuotaEnsure representationPracticalNot truly random

Psychometrics & Scale Development

Reliability

import numpy as np

def cronbachs_alpha(items_df):
    """Calculate Cronbach's alpha for scale reliability"""
    k = items_df.shape[1]
    item_vars = items_df.var(axis=0, ddof=1)
    total_var = items_df.sum(axis=1).var(ddof=1)
    alpha = (k / (k - 1)) * (1 - item_vars.sum() / total_var)
    return alpha

# Interpretation: α > 0.7 acceptable, > 0.8 good, > 0.9 excellent

Exploratory Factor Analysis

from sklearn.decomposition import FactorAnalysis
import numpy as np

# Determine number of factors (parallel analysis or scree plot)
fa = FactorAnalysis(n_components=3, rotation='varimax')
fa.fit(X_scaled)
loadings = pd.DataFrame(fa.components_.T, index=item_names, columns=['F1', 'F2', 'F3'])
print(loadings.round(3))
# Items loading > 0.4 on a factor belong to that construct

Confirmatory Factor Analysis / SEM

For CFA and SEM, recommend using R with lavaan package or Python semopy:

# pip install semopy
import semopy

model_spec = """
    Latent1 =~ item1 + item2 + item3
    Latent2 =~ item4 + item5 + item6
    Latent1 ~ Latent2
"""
model = semopy.Model(model_spec)
model.fit(df)
print(model.inspect())
# Check fit indices: CFI > 0.95, RMSEA < 0.06, SRMR < 0.08

Qualitative Analysis

Thematic Analysis (Braun & Clarke)

1. Familiarization: Read and re-read data 2. Initial coding: Generate codes systematically 3. Theme search: Collate codes into potential themes 4. Theme review: Check themes against coded extracts and full dataset 5. Theme definition: Name and define each theme 6. Report: Select vivid examples, relate to research question

Coding Framework Template

| Code | Definition | Example Quote | Theme |
|------|-----------|---------------|-------|
| ADAPT | Adaptation strategy | "We had to change our approach..." | Resilience |
| BARR | Barrier encountered | "The main obstacle was..." | Challenges |

Grounded Theory

1. Open coding → Axial coding → Selective coding 2. Constant comparison method 3. Theoretical sampling until saturation 4. Memo writing throughout

Content Analysis

# Quantitative content analysis
import pandas as pd
from collections import Counter

def content_analysis(texts, codebook):
    """
    codebook: dict of {category: [keywords]}
    Returns frequency matrix
    """
    results = []
    for text in texts:
        text_lower = text.lower()
        counts = {}
        for category, keywords in codebook.items():
            counts[category] = sum(text_lower.count(kw.lower()) for kw in keywords)
        results.append(counts)
    return pd.DataFrame(results)

# Inter-coder reliability (Cohen's Kappa)
from sklearn.metrics import cohen_kappa_score
kappa = cohen_kappa_score(coder1_labels, coder2_labels)
# κ > 0.8 excellent, 0.6-0.8 substantial, 0.4-0.6 moderate

Social Network Analysis

import networkx as nx
import numpy as np

G = nx.from_pandas_edgelist(df, 'source', 'target')

# Centrality measures
degree = nx.degree_centrality(G)
betweenness = nx.betweenness_centrality(G)
closeness = nx.closeness_centrality(G)
eigenvector = nx.eigenvector_centrality(G)

# Community detection
from networkx.algorithms.community import greedy_modularity_communities
communities = list(greedy_modularity_communities(G))

# Network statistics
print(f"Nodes: {G.number_of_nodes()}, Edges: {G.number_of_edges()}")
print(f"Density: {nx.density(G):.4f}")
print(f"Clustering coefficient: {nx.average_clustering(G):.4f}")

Tips

  • Pre-register hypotheses and analysis plans (OSF, AsPredicted)
  • Report Cronbach's alpha for all scales
  • Use power analysis for sample size determination
  • For qualitative research, document your positionality
  • Mixed methods: clearly state the integration strategy
  • IRB/ethics approval is mandatory for human subjects research

Related skills

FAQ

What methods does it cover?

Survey design, psychometrics and scale development, qualitative and content analysis, and social network analysis across sociology, psychology, political science, education, and communication.

Does it provide reliability tools?

Yes, including Cronbach's alpha for scale reliability and Cohen's kappa for inter-coder reliability.

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.