मुख्य सामग्री पर जाएँ
Skillpedia
मशीन लर्निंग51k · #3538

pydeseq2

यह क्या करती है

यह tool बड़े पैमाने के RNA data का विश्लेषण करके पता लगाता है कि अलग-अलग samples में कौन-से genes अपनी activity बदलते हैं। इससे जीवित जीवों पर किए गए प्रयोगों में जैविक अंतर समझने में मदद मिलती है।

कब इस्तेमाल करें

  • ✓किसी treatment group और control group के बीच gene activity की तुलना करने के लिए।
  • ✓किसी खास स्थिति (जैसे बीमारी बनाम स्वस्थ अवस्था) की वजह से बदलने वाले genes पहचानने के लिए।
  • ✓ऐसे प्रयोगों का विश्लेषण करने के लिए जिनमें कई जीव या samples इस्तेमाल हुए हों, ताकि नतीजे अधिक भरोसेमंद हों।

Skill का लिंक

https://github.com/K-Dense-AI/scientific-agent-skills/blob/main/skills/pydeseq2/SKILL.md

इसे कॉपी करके अपने AI (Claude, ChatGPT या Cursor) में पेस्ट करें और निर्देशों का पालन करने को कहें।

कैसे इस्तेमाल करें

सबसे आसान तरीका: मैसेज कॉपी करके अपने AI में पेस्ट करें। वह skill पढ़कर निर्देशों का पालन करेगा।

पेस्ट करने के लिए तैयार मैसेज

इस skill से मेरी मदद करो: https://github.com/K-Dense-AI/scientific-agent-skills/blob/main/skills/pydeseq2/SKILL.md इस लिंक की SKILL.md फ़ाइल पढ़ो और मेरे काम में उसके निर्देशों का पालन करो।
क्या आप चाहते हैं कि आपका AI ऐसी skills खुद ढूँढे?मुफ़्त Skillpedia MCP इंस्टॉल करें: बस एक लाइन, और हर काम से पहले यह 15,000+ skills में खोजता है।1 मिनट में इंस्टॉल करें →

AI से क्या माँगें: उदाहरण

“मेरे RNA-seq data का विश्लेषण करो और उन genes को ढूंढो जो 'treated' और 'control' group के बीच बदले हैं। इसके लिए ऐसा formula इस्तेमाल करो जिसमें 'batch' का हिसाब हो।”

हर हफ़्ते 5 नई skills, 1 मिनट में पढ़ें।

यह कैसे काम करती है

आप अपना gene count data और samples की जानकारी देते हैं। tool एक statistical model का इस्तेमाल करके आपके बनाए गए groups के बीच gene activity के स्तरों की तुलना करता है।

तकनीकी सामग्री (मूल SKILL.md)

लेखक का मूल टेक्स्ट, अंग्रेज़ी में, सीधे GitHub से।

PyDESeq2

Use this skill for bulk RNA-seq negative-binomial GLMs, with explicit biological replicates, covariates, and comparisons. Cells, sequencing lanes, and repeated measurements from the same donor are not independent biological replicates. Donor-level pseudobulk can be appropriate when its aggregation and design match the scientific question; this is not a single-cell per-cell testing workflow.

Current PyDESeq2 0.5.4 provides Wald tests and apeGLM-style coefficient shrinkage. Do not assume every feature or numerical result of current R DESeq2 is implemented identically. See API and tested versions for supported calls, AnnData storage, and source/runtime verification limits.

Analysis contract

  1. Establish the experimental unit, count provenance, sample exclusions, reference levels, and intended comparison before fitting. Use nonnegative integer counts in samples × genes order, with unique sample/gene IDs. TPM, FPKM, log data, VST data, and library-normalized counts are not model inputs. Integer checks alone cannot establish raw-count provenance. Approved estimated-count imports need an explicit upstream conversion and offset/length-correction policy.
  2. Require equal sample sets and reorder metadata to the count index. Resolve unmatched IDs and missing design annotations explicitly; never silently take an intersection. Determine orientation from the file schema, not its shape.
  3. Apply a prespecified gene prefilter after intentional sample exclusions. Total counts >=10 is a small example rule, not a universal biological threshold. Keep enough genes to estimate normalization and dispersion trends jointly.
  4. Build a full-rank formula design with residual degrees of freedom. Explicitly encode categories/reference levels; numeric variables are continuous. Formula term order does not decide the tested effect when a contrast is explicit.
  5. Fit size factors, gene-wise/trend/MAP dispersions, LFCs, and Cook diagnostics. Inspect warnings, convergence and normalization assumptions before interpreting results. Large size factors can reflect real library-depth differences.
  6. Test an explicit contrast with the intended alpha, preserve the full Wald table, and optionally shrink the same single positive coefficient. Export counts/model metadata separately from statistical results.

Quick start

Install in an isolated environment; the repository test runner supplies the scientific dependencies separately from the project environment:

uv venv --python 3.13 .venv-pydeseq2
uv pip install --python .venv-pydeseq2/bin/python 'pydeseq2==0.5.4' 'anndata==0.13.4'

Paths below are illustrative; run from this skill directory with your own files. The bundled driver expects counts CSV as genes × samples by default, and metadata CSV as samples × annotations, each with IDs in its first column:

python scripts/run_deseq2_analysis.py \
  --counts counts.csv --metadata metadata.csv \
  --design '~batch + condition' --contrast condition treated control \
  --min-counts 10 --alpha 0.05 --n-cpus 1 --plots --output results/

Use --no-transpose for a counts file already in samples × genes order. The driver rejects duplicate source CSV headers, unequal sample sets, invalid count values, zero-count samples, missing contrast annotations, and unidentifiable designs. It sets the CLI contrast variable's reference level before fitting; numeric category codes supplied as the contrast variable are deliberately treated as categories. Resolve other design variables' types and missing values in the input metadata.

The driver performs Wald testing and shrinkage by default. --no-shrink exports only unshrunk effect estimates; --shrink-coeff can select only the coefficient that exactly matches the tested contrast. For interactions, continuous effects, or custom design matrices, use the Python patterns rather than guessing a CLI coefficient. The CLI does not expose thresholded tests or alternative normalization methods; use the API for those choices.

Outputs:

  • deseq2_results.csv: current estimates (shrunken if requested) with original Wald stat, pvalue, and padj.
  • deseq2_results_unshrunken.csv: preserved original Wald table.
  • significant_genes.csv and results_sorted_by_padj.csv: the configured alpha

…

अक्सर पूछे जाने वाले सवाल

'biological replicates' क्या होते हैं?

ये एक ही तरह के जीव या स्थिति के स्वतंत्र samples होते हैं, जिनसे यह सुनिश्चित होता है कि नतीजे केवल संयोग की वजह से न हों।

'log2FoldChange' क्या है?

यह मापता है कि दो स्थितियों के बीच किसी gene की activity कितनी बदली। सकारात्मक मान का मतलब है कि वह बढ़ी है, और नकारात्मक मान का मतलब है कि वह घटी है।

'padj' (adjusted p-value) क्या है?

यह एक मान है जो बताता है कि किए गए बहुत सारे tests को सुधारने के बाद नतीजा गलत होने की कितनी संभावना है। कम 'padj' का मतलब है कि नतीजा भरोसेमंद है।

जानकारी

लेखक का मूल विवरण

Performs bulk RNA-seq differential expression analysis with PyDESeq2, including count validation, formula designs, explicit contrasts, Wald tests, FDR correction, coefficient-matched LFC shrinkage, and result visualization. Use for PyDESeq2 or Python DESeq2 workflows with biological replicates.

repo: K-Dense-AI/scientific-agent-skills

लोकप्रियता

GitHub स्टार
51k
रैंकिंग में स्थान
#3538
लाइसेंस
MIT
अपडेट की गई
15/10/2026

क्या यह skill काम की है?

0

लॉग इन करें वोट करने के लिए।

कमेंट

  • …

इस repository की और skills

13c-metabolic-flux

51k

कार्बन-13 आइसोटोप ट्रेसिंग डेटा से मेटाबोलिक फ़्लक्स का अनुमान लगाता है। कोशिका के मेटाबॉलिज़्म और बायोकेमिकल मार्गों का विश्लेषण करने के लिए यह उपयोगी है।

AI और एजेंटएजेंट

adaptyv

51k

Adaptyv API का उपयोग करके प्रोटीन कैरेक्टराइज़ेशन प्रयोग डिज़ाइन करता है। लागत का अनुमान लगाने, सीक्वेंस सबमिट करने और लैब के नतीजों पर नज़र रखने में मदद करता है।

AI और एजेंटएजेंट

aeon

51k

टाइम सीरीज़ डेटा पर मशीन लर्निंग के काम करता है। क्रमबद्ध डेटा में वर्गीकरण, पूर्वानुमान, एनोमली डिटेक्शन और पैटर्न खोजने के लिए यह उपयोगी है।

AI और एजेंटएजेंट

alphagenome

51k

जेनेटिक वेरिएंट्स के पहले से गणना किए गए जीनोमिक प्रभाव देखता है। वेरिएंट का जीनोम पर असर समझने के लिए स्कोर और स्पष्टीकरण देता है।

डेटामशीन लर्निंग

मिलती-जुलती skills