[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7BKDH418BKSVBWDGXPQZCZB":3,"skill-same:01M7BKDH418BKSVBWDGXPQZCZB":53},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":24,"commitSha":25,"skillDirectory":26,"forksCount":27,"repositoryHtmlUrl":28,"repositoryHomepageUrl":29,"ownerHtmlUrl":30,"ownerBlogUrl":6,"ownerDescription":31,"updatedAt":32,"install":33,"resources":46},"01M7BKDH418BKSVBWDGXPQZCZB","scikit-bio",null,"Biological data toolkit. Sequence analysis, alignments, phylogenetic trees, diversity metrics (alpha\u002Fbeta, UniFrac), ordination (PCoA), PERMANOVA, FASTA\u002FNewick I\u002FO, for microbiome analysis.","YYC-Cube\u002FYYC3-Knowledge-Base","YYC-Cube","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F235006543?v=4","01M79J2PH4SWD2X0825X6PN748","yyc3","01M79J2PHVK3F6ZBYT8K2SCZCW",1,"MIT","https:\u002F\u002Fgithub.com\u002FYYC-Cube\u002FYYC3-Knowledge-Base\u002Fblob\u002Fmain\u002FYYC3-AI-应用工具\u002FYYC3-AI-应用工具-claude-code-templates-main\u002Fcli-tool\u002Fcomponents\u002Fskills\u002Fscientific\u002Fscikit-bio\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: scikit-bio\ndescription: \"Biological data toolkit. Sequence analysis, alignments, phylogenetic trees, diversity metrics (alpha\u002Fbeta, UniFrac), ordination (PCoA), PERMANOVA, FASTA\u002FNewick I\u002FO, for microbiome analysis.\"\n---\n\n# scikit-bio\n\n## Overview\n\nscikit-bio is a comprehensive Python library for working with biological data. Apply this skill for bioinformatics analyses spanning sequence manipulation, alignment, phylogenetics, microbial ecology, and multivariate statistics.\n\n## When to Use This Skill\n\nThis skill should be used when the user:\n- Works with biological sequences (DNA, RNA, protein)\n- Needs to read\u002Fwrite biological file formats (FASTA, FASTQ, GenBank, Newick, BIOM, etc.)\n- Performs sequence alignments or searches for motifs\n- Constructs or analyzes phylogenetic trees\n- Calculates diversity metrics (alpha\u002Fbeta diversity, UniFrac distances)\n- Performs ordination analysis (PCoA, CCA, RDA)\n- Runs statistical tests on biological\u002Fecological data (PERMANOVA, ANOSIM, Mantel)\n- Analyzes microbiome or community ecology data\n- Works with protein embeddings from language models\n- Needs to manipulate biological data tables\n\n## Core Capabilities\n\n### 1. Sequence Manipulation\n\nWork with biological sequences using specialized classes for DNA, RNA, and protein data.\n\n**Key operations:**\n- Read\u002Fwrite sequences from FASTA, FASTQ, GenBank, EMBL formats\n- Sequence slicing, concatenation, and searching\n- Reverse complement, transcription (DNA→RNA), and translation (RNA→protein)\n- Find motifs and patterns using regex\n- Calculate distances (Hamming, k-mer based)\n- Handle sequence quality scores and metadata\n\n**Common patterns:**\n```python\nimport skbio\n\n# Read sequences from file\nseq = skbio.DNA.read('input.fasta')\n\n# Sequence operations\nrc = seq.reverse_complement()\nrna = seq.transcribe()\nprotein = rna.translate()\n\n# Find motifs\nmotif_positions = seq.find_with_regex('ATG[ACGT]{3}')\n\n# Check for properties\nhas_degens = seq.has_degenerates()\nseq_no_gaps = seq.degap()\n```\n\n**Important notes:**\n- Use `DNA`, `RNA`, `Protein` classes for grammared sequences with validation\n- Use `Sequence` class for generic sequences without alphabet restrictions\n- Quality scores automatically loaded from FASTQ files into positional metadata\n- Metadata types: sequence-level (ID, description), positional (per-base), interval (regions\u002Ffeatures)\n\n### 2. Sequence Alignment\n\nPerform pairwise and multiple sequence alignments using dynamic programming algorithms.\n\n**Key capabilities:**\n- Global alignment (Needleman-Wunsch with semi-global variant)\n- Local alignment (Smith-Waterman)\n- Configurable scoring schemes (match\u002Fmismatch, gap penalties, substitution matrices)\n- CIGAR string conversion\n- Multiple sequence alignment storage and manipulation with `TabularMSA`\n\n**Common patterns:**\n```python\nfrom skbio.alignment import local_pairwise_align_ssw, TabularMSA\n\n# Pairwise alignment\nalignment = local_pairwise_align_ssw(seq1, seq2)\n\n# Access aligned sequences\nmsa = alignment.aligned_sequences\n\n# Read multiple alignment from file\nmsa = TabularMSA.read('alignment.fasta', constructor=skbio.DNA)\n\n# Calculate consensus\nconsensus = msa.consensus()\n```\n\n**Important notes:**\n- Use `local_pairwise_align_ssw` for local alignments (faster, SSW-based)\n- Use `StripedSmithWaterman` for protein alignments\n- Affine gap penalties recommended for biological sequences\n- Can convert between scikit-bio, BioPython, and Biotite alignment formats\n\n### 3. Phylogenetic Trees\n\nConstruct, manipulate, and analyze phylogenetic trees representing evolutionary relationships.\n\n**Key capabilities:**\n- Tree construction from distance matrices (UPGMA, WPGMA, Neighbor Joining, GME, BME)\n- Tree manipulation (pruning, rerooting, traversal)\n- Distance calculations (patristic, cophenetic, Robinson-Foulds)\n- ASCII visualization\n- Newick format I\u002FO\n\n**Common patterns:**\n```python\nfrom skbio import TreeNode\nfrom skbio.tree import nj\n\n# Read tree from file\ntree = TreeNode.read('tree.nwk')\n\n# Construct tree from distance matrix\ntree = nj(distance_matrix)\n\n# Tree operations\nsubtree = tree.shear(['taxon1', 'taxon2', 'taxon3'])\ntips = [node for node in tree.tips()]\nlca = tree.lowest_common_ancestor(['taxon1', 'taxon2'])\n\n# Calculate distances\npatristic_dist = tree.find('taxon1').distance(tree.find('taxon2'))\ncophenetic_matrix = tree.cophenetic_matrix()\n\n# Compare trees\nrf_distance = tree.robinson_foulds(other_tree)\n```\n\n**Important notes:**\n- Use `nj()` for neighbor joining (classic phylogenetic method)\n- Use `upgma()` for UPGMA (assumes molecular clock)\n- GME and BME are highly scalable for large trees\n- Trees can be rooted or unrooted; some metrics require specific rooting\n\n### 4. Diversity Analysis\n\nCalculate alpha and beta diversity metrics for microbial ecology and community analysis.\n\n**Key capabilities:**\n- Alpha diversity: richness, Shannon entropy, Simpson index, Faith's PD, Pielou's evenness\n- Beta diversity: Bray-Curtis, Jaccard, weighted\u002Funweighted UniFrac, Euclidean distances\n- Phylogenetic diversity metrics (require tree input)\n- Rarefaction and subsampling\n- Integration with ordination and statistical tests\n\n**Common patterns:**\n```python\nfrom skbio.diversity import alpha_diversity, beta_diversity\nimport skbio\n\n# Alpha diversity\nalpha = alpha_diversity('shannon', counts_matrix, ids=sample_ids)\nfaith_pd = alpha_diversity('faith_pd', counts_matrix, ids=sample_ids,\n                          tree=tree, otu_ids=feature_ids)\n\n# Beta diversity\nbc_dm = beta_diversity('braycurtis', counts_matrix, ids=sample_ids)\nunifrac_dm = beta_diversity('unweighted_unifrac', counts_matrix,\n                           ids=sample_ids, tree=tree, otu_ids=feature_ids)\n\n# Get available metrics\nfrom skbio.diversity import get_alpha_diversity_metrics\nprint(get_alpha_diversity_metrics())\n```\n\n**Important notes:**\n- Counts must be integers representing abundances, not relative frequencies\n- Phylogenetic metrics (Faith's PD, UniFrac) require tree and OTU ID mapping\n- Use `partial_beta_diversity()` for computing specific sample pairs only\n- Alpha diversity returns Series, beta diversity returns DistanceMatrix\n\n### 5. Ordination Methods\n\nReduce high-dimensional biological data to visualizable lower-dimensional spaces.\n\n**Key capabilities:**\n- PCoA (Principal Coordinate Analysis) from distance matrices\n- CA (Correspondence Analysis) for contingency tables\n- CCA (Canonical Correspondence Analysis) with environmental constraints\n- RDA (Redundancy Analysis) for linear relationships\n- Biplot projection for feature interpretation\n\n**Common patterns:**\n```python\nfrom skbio.stats.ordination import pcoa, cca\n\n# PCoA from distance matrix\npcoa_results = pcoa(distance_matrix)\npc1 = pcoa_results.samples['PC1']\npc2 = pcoa_results.samples['PC2']\n\n# CCA with environmental variables\ncca_results = cca(species_matrix, environmental_matrix)\n\n# Save\u002Fload ordination results\npcoa_results.write('ordination.txt')\nresults = skbio.OrdinationResults.read('ordination.txt')\n```\n\n**Important notes:**\n- PCoA works with any distance\u002Fdissimilarity matrix\n- CCA reveals environmental drivers of community composition\n- Ordination results include eigenvalues, proportion explained, and sample\u002Ffeature coordinates\n- Results integrate with plotting libraries (matplotlib, seaborn, plotly)\n\n### 6. Statistical Testing\n\nPerform hypothesis tests specific to ecological and biological data.\n\n**Key capabilities:**\n- PERMANOVA: test group differences using distance matrices\n- ANOSIM: alternative test for group differences\n- PERMDISP: test homogeneity of group dispersions\n- Mantel test: correlation between distance matrices\n- Bioenv: find environmental variables correlated with distances\n\n**Common patterns:**\n```python\nfrom skbio.stats.distance import permanova, anosim, mantel\n\n# Test if groups differ significantly\npermanova_results = permanova(distance_matrix, grouping, permutations=999)\nprint(f\"p-value: {permanova_results['p-value']}\")\n\n# ANOSIM test\nanosim_results = anosim(distance_matrix, grouping, permutations=999)\n\n# Mantel test between two distance matrices\nmantel_results = mantel(dm1, dm2, method='pearson', permutations=999)\nprint(f\"Correlation: {mantel_results[0]}, p-value: {mantel_results[1]}\")\n```\n\n**Important notes:**\n- Permutation tests provide non-parametric significance testing\n- Use 999+ permutations for robust p-values\n- PERMANOVA sensitive to dispersion differences; pair with PERMDISP\n- Mantel tests assess matrix correlation (e.g., geographic vs genetic distance)\n\n### 7. File I\u002FO and Format Conversion\n\nRead and write 19+ biological file formats with automatic format detection.\n\n**Supported formats:**\n- Sequences: FASTA, FASTQ, GenBank, EMBL, QSeq\n- Alignments: Clustal, PHYLIP, Stockholm\n- Trees: Newick\n- Tables: BIOM (HDF5 and JSON)\n- Distances: delimited square matrices\n- Analysis: BLAST+6\u002F7, GFF3, Ordination results\n- Metadata: TSV\u002FCSV with validation\n\n**Common patterns:**\n```python\nimport skbio\n\n# Read with automatic format detection\nseq = skbio.DNA.read('file.fasta', format='fasta')\ntree = skbio.TreeNode.read('tree.nwk')\n\n# Write to file\nseq.write('output.fasta', format='fasta')\n\n# Generator for large files (memory efficient)\nfor seq in skbio.io.read('large.fasta', format='fasta', constructor=skbio.DNA):\n    process(seq)\n\n# Convert formats\nseqs = list(skbio.io.read('input.fastq', format='fastq', constructor=skbio.DNA))\nskbio.io.write(seqs, format='fasta', into='output.fasta')\n```\n\n**Important notes:**\n- Use generators for large files to avoid memory issues\n- Format can be auto-detected when `into` parameter specified\n- Some objects can be written to multiple formats\n- Support for stdin\u002Fstdout piping with `verify=False`\n\n### 8. Distance Matrices\n\nCreate and manipulate distance\u002Fdissimilarity matrices with statistical methods.\n\n**Key capabilities:**\n- Store symmetric (DistanceMatrix) or asymmetric (DissimilarityMatrix) data\n- ID-based indexing and slicing\n- Integration with diversity, ordination, and statistical tests\n- Read\u002Fwrite delimited text format\n\n**Common patterns:**\n```python\nfrom skbio import DistanceMatrix\nimport numpy as np\n\n# Create from array\ndata = np.array([[0, 1, 2], [1, 0, 3], [2, 3, 0]])\ndm = DistanceMatrix(data, ids=['A', 'B', 'C'])\n\n# Access distances\ndist_ab = dm['A', 'B']\nrow_a = dm['A']\n\n# Read from file\ndm = DistanceMatrix.read('distances.txt')\n\n# Use in downstream analyses\npcoa_results = pcoa(dm)\npermanova_results = permanova(dm, grouping)\n```\n\n**Important notes:**\n- DistanceMatrix enforces symmetry and zero diagonal\n- DissimilarityMatrix allows asymmetric values\n- IDs enable integration with metadata and biological knowledge\n- Compatible with pandas, numpy, and scikit-learn\n\n### 9. Biological Tables\n\nWork with feature tables (OTU\u002FASV tables) common in microbiome research.\n\n**Key capabilities:**\n- BIOM format I\u002FO (HDF5 and JSON)\n- Integration with pandas, polars, AnnData, numpy\n- Data augmentation techniques (phylomix, mixup, compositional methods)\n- Sample\u002Ffeature filtering and normalization\n- Metadata integration\n\n**Common patterns:**\n```python\nfrom skbio import Table\n\n# Read BIOM table\ntable = Table.read('table.biom')\n\n# Access data\nsample_ids = table.ids(axis='sample')\nfeature_ids = table.ids(axis='observation')\ncounts = table.matrix_data\n\n# Filter\nfiltered = table.filter(sample_ids_to_keep, axis='sample')\n\n# Convert to\u002Ffrom pandas\ndf = table.to_dataframe()\ntable = Table.from_dataframe(df)\n```\n\n**Important notes:**\n- BIOM tables are standard in QIIME 2 workflows\n- Rows typically represent samples, columns represent features (OTUs\u002FASVs)\n- Supports sparse and dense representations\n- Output format configurable (pandas\u002Fpolars\u002Fnumpy)\n\n### 10. Protein Embeddings\n\nWork with protein language model embeddings for downstream analysis.\n\n**Key capabilities:**\n- Store embeddings from protein language models (ESM, ProtTrans, etc.)\n- Convert embeddings to distance matrices\n- Generate ordination objects for visualization\n- Export to numpy\u002Fpandas for ML workflows\n\n**Common patterns:**\n```python\nfrom skbio.embedding import ProteinEmbedding, ProteinVector\n\n# Create embedding from array\nembedding = ProteinEmbedding(embedding_array, sequence_ids)\n\n# Convert to distance matrix for analysis\ndm = embedding.to_distances(metric='euclidean')\n\n# PCoA visualization of embedding space\npcoa_results = embedding.to_ordination(metric='euclidean', method='pcoa')\n\n# Export for machine learning\narray = embedding.to_array()\ndf = embedding.to_dataframe()\n```\n\n**Important notes:**\n- Embeddings bridge protein language models with traditional bioinformatics\n- Compatible with scikit-bio's distance\u002Fordination\u002Fstatistics ecosystem\n- SequenceEmbedding and ProteinEmbedding provide specialized functionality\n- Useful for sequence clustering, classification, and visualization\n\n## Best Practices\n\n### Installation\n```bash\nuv pip install scikit-bio\n```\n\n### Performance Considerations\n- Use generators for large sequence files to minimize memory usage\n- For massive phylogenetic trees, prefer GME or BME over NJ\n- Beta diversity calculations can be parallelized with `partial_beta_diversity()`\n- BIOM format (HDF5) more efficient than JSON for large tables\n\n### Integration with Ecosystem\n- Sequences interoperate with Biopython via standard formats\n- Tables integrate with pandas, polars, and AnnData\n- Distance matrices compatible with scikit-learn\n- Ordination results visualizable with matplotlib\u002Fseaborn\u002Fplotly\n- Works seamlessly with QIIME 2 artifacts (BIOM, trees, distance matrices)\n\n### Common Workflows\n1. **Microbiome diversity analysis**: Read BIOM table → Calculate alpha\u002Fbeta diversity → Ordination (PCoA) → Statistical testing (PERMANOVA)\n2. **Phylogenetic analysis**: Read sequences → Align → Build distance matrix → Construct tree → Calculate phylogenetic distances\n3. **Sequence processing**: Read FASTQ → Quality filter → Trim\u002Fclean → Find motifs → Translate → Write FASTA\n4. **Comparative genomics**: Read sequences → Pairwise alignment → Calculate distances → Build tree → Analyze clades\n\n## Reference Documentation\n\nFor detailed API information, parameter specifications, and advanced usage examples, refer to `references\u002Fapi_reference.md` which contains comprehensive documentation on:\n- Complete method signatures and parameters for all capabilities\n- Extended code examples for complex workflows\n- Troubleshooting common issues\n- Performance optimization tips\n- Integration patterns with other libraries\n\n## Additional Resources\n\n- Official documentation: https:\u002F\u002Fscikit.bio\u002Fdocs\u002Flatest\u002F\n- GitHub repository: https:\u002F\u002Fgithub.com\u002Fscikit-bio\u002Fscikit-bio\n- Forum support: https:\u002F\u002Fforum.qiime2.org (scikit-bio is part of QIIME 2 ecosystem)\n","# scikit-bio\n\n## Overview\n\nscikit-bio is a comprehensive Python library for working with biological data. Apply this skill for bioinformatics analyses spanning sequence manipulation, alignment, phylogenetics, microbial ecology, and multivariate statistics.\n\n## When to Use This Skill\n\nThis skill should be used when the user:\n- Works with biological sequences (DNA, RNA, protein)\n- Needs to read\u002Fwrite biological file formats (FASTA, FASTQ, GenBank, Newick, BIOM, etc.)\n- Performs sequence alignments or searches for motifs\n- Constructs or analyzes phylogenetic trees\n- Calculates diversity metrics (alpha\u002Fbeta diversity, UniFrac distances)\n- Performs ordination analysis (PCoA, CCA, RDA)\n- Runs statistical tests on biological\u002Fecological data (PERMANOVA, ANOSIM, Mantel)\n- Analyzes microbiome or community ecology data\n- Works with protein embeddings from language models\n- Needs to manipulate biological data tables\n\n## Core Capabilities\n\n### 1. Sequence Manipulation\n\nWork with biological sequences using specialized classes for DNA, RNA, and protein data.\n\n**Key operations:**\n- Read\u002Fwrite sequences from FASTA, FASTQ, GenBank, EMBL formats\n- Sequence slicing, concatenation, and searching\n- Reverse complement, transcription (DNA→RNA), and translation (RNA→protein)\n- Find motifs and patterns using regex\n- Calculate distances (Hamming, k-mer based)\n- Handle sequence quality scores and metadata\n\n**Common patterns:**\n```python\nimport skbio\n\n# Read sequences from file\nseq = skbio.DNA.read('input.fasta')\n\n# Sequence operations\nrc = seq.reverse_complement()\nrna = seq.transcribe()\nprotein = rna.translate()\n\n# Find motifs\nmotif_positions = seq.find_with_regex('ATG[ACGT]{3}')\n\n# Check for properties\nhas_degens = seq.has_degenerates()\nseq_no_gaps = seq.degap()\n```\n\n**Important notes:**\n- Use `DNA`, `RNA`, `Protein` classes for grammared sequences with validation\n- Use `Sequence` class for generic sequences without alphabet restrictions\n- Quality scores automatically loaded from FASTQ files into positional metadata\n- Metadata types: sequence-level (ID, description), positional (per-base), interval (regions\u002Ffeatures)\n\n### 2. Sequence Alignment\n\nPerform pairwise and multiple sequence alignments using dynamic programming algorithms.\n\n**Key capabilities:**\n- Global alignment (Needleman-Wunsch with semi-global variant)\n- Local alignment (Smith-Waterman)\n- Configurable scoring schemes (match\u002Fmismatch, gap penalties, substitution matrices)\n- CIGAR string conversion\n- Multiple sequence alignment storage and manipulation with `TabularMSA`\n\n**Common patterns:**\n```python\nfrom skbio.alignment import local_pairwise_align_ssw, TabularMSA\n\n# Pairwise alignment\nalignment = local_pairwise_align_ssw(seq1, seq2)\n\n# Access aligned sequences\nmsa = alignment.aligned_sequences\n\n# Read multiple alignment from file\nmsa = TabularMSA.read('alignment.fasta', constructor=skbio.DNA)\n\n# Calculate consensus\nconsensus = msa.consensus()\n```\n\n**Important notes:**\n- Use `local_pairwise_align_ssw` for local alignments (faster, SSW-based)\n- Use `StripedSmithWaterman` for protein alignments\n- Affine gap penalties recommended for biological sequences\n- Can convert between scikit-bio, BioPython, and Biotite alignment formats\n\n### 3. Phylogenetic Trees\n\nConstruct, manipulate, and analyze phylogenetic trees representing evolutionary relationships.\n\n**Key capabilities:**\n- Tree construction from distance matrices (UPGMA, WPGMA, Neighbor Joining, GME, BME)\n- Tree manipulation (pruning, rerooting, traversal)\n- Distance calculations (patristic, cophenetic, Robinson-Foulds)\n- ASCII visualization\n- Newick format I\u002FO\n\n**Common patterns:**\n```python\nfrom skbio import TreeNode\nfrom skbio.tree import nj\n\n# Read tree from file\ntree = TreeNode.read('tree.nwk')\n\n# Construct tree from distance matrix\ntree = nj(distance_matrix)\n\n# Tree operations\nsubtree = tree.shear(['taxon1', 'taxon2', 'taxon3'])\ntips = [node for node in tree.tips()]\nlca = tree.lowest_common_ancestor(['taxon1', 'taxon2'])\n\n# Calculate distances\npatristic_dist = tree.find('taxon1').distance(tree.find('taxon2'))\ncophenetic_matrix = tree.cophenetic_matrix()\n\n# Compare trees\nrf_distance = tree.robinson_foulds(other_tree)\n```\n\n**Important notes:**\n- Use `nj()` for neighbor joining (classic phylogenetic method)\n- Use `upgma()` for UPGMA (assumes molecular clock)\n- GME and BME are highly scalable for large trees\n- Trees can be rooted or unrooted; some metrics require specific rooting\n\n### 4. Diversity Analysis\n\nCalculate alpha and beta diversity metrics for microbial ecology and community analysis.\n\n**Key capabilities:**\n- Alpha diversity: richness, Shannon entropy, Simpson index, Faith's PD, Pielou's evenness\n- Beta diversity: Bray-Curtis, Jaccard, weighted\u002Funweighted UniFrac, Euclidean distances\n- Phylogenetic diversity metrics (require tree input)\n- Rarefaction and subsampling\n- Integration with ordination and statistical tests\n\n**Common patterns:**\n```python\nfrom skbio.diversity import alpha_diversity, beta_diversity\nimport skbio\n\n# Alpha diversity\nalpha = alpha_diversity('shannon', counts_matrix, ids=sample_ids)\nfaith_pd = alpha_diversity('faith_pd', counts_matrix, ids=sample_ids,\n                          tree=tree, otu_ids=feature_ids)\n\n# Beta diversity\nbc_dm = beta_diversity('braycurtis', counts_matrix, ids=sample_ids)\nunifrac_dm = beta_diversity('unweighted_unifrac', counts_matrix,\n                           ids=sample_ids, tree=tree, otu_ids=feature_ids)\n\n# Get available metrics\nfrom skbio.diversity import get_alpha_diversity_metrics\nprint(get_alpha_diversity_metrics())\n```\n\n**Important notes:**\n- Counts must be integers representing abundances, not relative frequencies\n- Phylogenetic metrics (Faith's PD, UniFrac) require tree and OTU ID mapping\n- Use `partial_beta_diversity()` for computing specific sample pairs only\n- Alpha diversity returns Series, beta diversity returns DistanceMatrix\n\n### 5. Ordination Methods\n\nReduce high-dimensional biological data to visualizable lower-dimensional spaces.\n\n**Key capabilities:**\n- PCoA (Principal Coordinate Analysis) from distance matrices\n- CA (Correspondence Analysis) for contingency tables\n- CCA (Canonical Correspondence Analysis) with environmental constraints\n- RDA (Redundancy Analysis) for linear relationships\n- Biplot projection for feature interpretation\n\n**Common patterns:**\n```python\nfrom skbio.stats.ordination import pcoa, cca\n\n# PCoA from distance matrix\npcoa_results = pcoa(distance_matrix)\npc1 = pcoa_results.samples['PC1']\npc2 = pcoa_results.samples['PC2']\n\n# CCA with environmental variables\ncca_results = cca(species_matrix, environmental_matrix)\n\n# Save\u002Fload ordination results\npcoa_results.write('ordination.txt')\nresults = skbio.OrdinationResults.read('ordination.txt')\n```\n\n**Important notes:**\n- PCoA works with any distance\u002Fdissimilarity matrix\n- CCA reveals environmental drivers of community composition\n- Ordination results include eigenvalues, proportion explained, and sample\u002Ffeature coordinates\n- Results integrate with plotting libraries (matplotlib, seaborn, plotly)\n\n### 6. Statistical Testing\n\nPerform hypothesis tests specific to ecological and biological data.\n\n**Key capabilities:**\n- PERMANOVA: test group differences using distance matrices\n- ANOSIM: alternative test for group differences\n- PERMDISP: test homogeneity of group dispersions\n- Mantel test: correlation between distance matrices\n- Bioenv: find environmental variables correlated with distances\n\n**Common patterns:**\n```python\nfrom skbio.stats.distance import permanova, anosim, mantel\n\n# Test if groups differ significantly\npermanova_results = permanova(distance_matrix, grouping, permutations=999)\nprint(f\"p-value: {permanova_results['p-value']}\")\n\n# ANOSIM test\nanosim_results = anosim(distance_matrix, grouping, permutations=999)\n\n# Mantel test between two distance matrices\nmantel_results = mantel(dm1, dm2, method='pearson', permutations=999)\nprint(f\"Correlation: {mantel_results[0]}, p-value: {mantel_results[1]}\")\n```\n\n**Important notes:**\n- Permutation tests provide non-parametric significance testing\n- Use 999+ permutations for robust p-values\n- PERMANOVA sensitive to dispersion differences; pair with PERMDISP\n- Mantel tests assess matrix correlation (e.g., geographic vs genetic distance)\n\n### 7. File I\u002FO and Format Conversion\n\nRead and write 19+ biological file formats with automatic format detection.\n\n**Supported formats:**\n- Sequences: FASTA, FASTQ, GenBank, EMBL, QSeq\n- Alignments: Clustal, PHYLIP, Stockholm\n- Trees: Newick\n- Tables: BIOM (HDF5 and JSON)\n- Distances: delimited square matrices\n- Analysis: BLAST+6\u002F7, GFF3, Ordination results\n- Metadata: TSV\u002FCSV with validation\n\n**Common patterns:**\n```python\nimport skbio\n\n# Read with automatic format detection\nseq = skbio.DNA.read('file.fasta', format='fasta')\ntree = skbio.TreeNode.read('tree.nwk')\n\n# Write to file\nseq.write('output.fasta', format='fasta')\n\n# Generator for large files (memory efficient)\nfor seq in skbio.io.read('large.fasta', format='fasta', constructor=skbio.DNA):\n    process(seq)\n\n# Convert formats\nseqs = list(skbio.io.read('input.fastq', format='fastq', constructor=skbio.DNA))\nskbio.io.write(seqs, format='fasta', into='output.fasta')\n```\n\n**Important notes:**\n- Use generators for large files to avoid memory issues\n- Format can be auto-detected when `into` parameter specified\n- Some objects can be written to multiple formats\n- Support for stdin\u002Fstdout piping with `verify=False`\n\n### 8. Distance Matrices\n\nCreate and manipulate distance\u002Fdissimilarity matrices with statistical methods.\n\n**Key capabilities:**\n- Store symmetric (DistanceMatrix) or asymmetric (DissimilarityMatrix) data\n- ID-based indexing and slicing\n- Integration with diversity, ordination, and statistical tests\n- Read\u002Fwrite delimited text format\n\n**Common patterns:**\n```python\nfrom skbio import DistanceMatrix\nimport numpy as np\n\n# Create from array\ndata = np.array([[0, 1, 2], [1, 0, 3], [2, 3, 0]])\ndm = DistanceMatrix(data, ids=['A', 'B', 'C'])\n\n# Access distances\ndist_ab = dm['A', 'B']\nrow_a = dm['A']\n\n# Read from file\ndm = DistanceMatrix.read('distances.txt')\n\n# Use in downstream analyses\npcoa_results = pcoa(dm)\npermanova_results = permanova(dm, grouping)\n```\n\n**Important notes:**\n- DistanceMatrix enforces symmetry and zero diagonal\n- DissimilarityMatrix allows asymmetric values\n- IDs enable integration with metadata and biological knowledge\n- Compatible with pandas, numpy, and scikit-learn\n\n### 9. Biological Tables\n\nWork with feature tables (OTU\u002FASV tables) common in microbiome research.\n\n**Key capabilities:**\n- BIOM format I\u002FO (HDF5 and JSON)\n- Integration with pandas, polars, AnnData, numpy\n- Data augmentation techniques (phylomix, mixup, compositional methods)\n- Sample\u002Ffeature filtering and normalization\n- Metadata integration\n\n**Common patterns:**\n```python\nfrom skbio import Table\n\n# Read BIOM table\ntable = Table.read('table.biom')\n\n# Access data\nsample_ids = table.ids(axis='sample')\nfeature_ids = table.ids(axis='observation')\ncounts = table.matrix_data\n\n# Filter\nfiltered = table.filter(sample_ids_to_keep, axis='sample')\n\n# Convert to\u002Ffrom pandas\ndf = table.to_dataframe()\ntable = Table.from_dataframe(df)\n```\n\n**Important notes:**\n- BIOM tables are standard in QIIME 2 workflows\n- Rows typically represent samples, columns represent features (OTUs\u002FASVs)\n- Supports sparse and dense representations\n- Output format configurable (pandas\u002Fpolars\u002Fnumpy)\n\n### 10. Protein Embeddings\n\nWork with protein language model embeddings for downstream analysis.\n\n**Key capabilities:**\n- Store embeddings from protein language models (ESM, ProtTrans, etc.)\n- Convert embeddings to distance matrices\n- Generate ordination objects for visualization\n- Export to numpy\u002Fpandas for ML workflows\n\n**Common patterns:**\n```python\nfrom skbio.embedding import ProteinEmbedding, ProteinVector\n\n# Create embedding from array\nembedding = ProteinEmbedding(embedding_array, sequence_ids)\n\n# Convert to distance matrix for analysis\ndm = embedding.to_distances(metric='euclidean')\n\n# PCoA visualization of embedding space\npcoa_results = embedding.to_ordination(metric='euclidean', method='pcoa')\n\n# Export for machine learning\narray = embedding.to_array()\ndf = embedding.to_dataframe()\n```\n\n**Important notes:**\n- Embeddings bridge protein language models with traditional bioinformatics\n- Compatible with scikit-bio's distance\u002Fordination\u002Fstatistics ecosystem\n- SequenceEmbedding and ProteinEmbedding provide specialized functionality\n- Useful for sequence clustering, classification, and visualization\n\n## Best Practices\n\n### Installation\n```bash\nuv pip install scikit-bio\n```\n\n### Performance Considerations\n- Use generators for large sequence files to minimize memory usage\n- For massive phylogenetic trees, prefer GME or BME over NJ\n- Beta diversity calculations can be parallelized with `partial_beta_diversity()`\n- BIOM format (HDF5) more efficient than JSON for large tables\n\n### Integration with Ecosystem\n- Sequences interoperate with Biopython via standard formats\n- Tables integrate with pandas, polars, and AnnData\n- Distance matrices compatible with scikit-learn\n- Ordination results visualizable with matplotlib\u002Fseaborn\u002Fplotly\n- Works seamlessly with QIIME 2 artifacts (BIOM, trees, distance matrices)\n\n### Common Workflows\n1. **Microbiome diversity analysis**: Read BIOM table → Calculate alpha\u002Fbeta diversity → Ordination (PCoA) → Statistical testing (PERMANOVA)\n2. **Phylogenetic analysis**: Read sequences → Align → Build distance matrix → Construct tree → Calculate phylogenetic distances\n3. **Sequence processing**: Read FASTQ → Quality filter → Trim\u002Fclean → Find motifs → Translate → Write FASTA\n4. **Comparative genomics**: Read sequences → Pairwise alignment → Calculate distances → Build tree → Analyze clades\n\n## Reference Documentation\n\nFor detailed API information, parameter specifications, and advanced usage examples, refer to `references\u002Fapi_reference.md` which contains comprehensive documentation on:\n- Complete method signatures and parameters for all capabilities\n- Extended code examples for complex workflows\n- Troubleshooting common issues\n- Performance optimization tips\n- Integration patterns with other libraries\n\n## Additional Resources\n\n- Official documentation: https:\u002F\u002Fscikit.bio\u002Fdocs\u002Flatest\u002F\n- GitHub repository: https:\u002F\u002Fgithub.com\u002Fscikit-bio\u002Fscikit-bio\n- Forum support: https:\u002F\u002Fforum.qiime2.org (scikit-bio is part of QIIME 2 ecosystem)\n",{"name":5,"description":7},"main","87afe6ce96220accf50a345dea46784c8c9f210e","YYC3-AI-应用工具\u002FYYC3-AI-应用工具-claude-code-templates-main\u002Fcli-tool\u002Fcomponents\u002Fskills\u002Fscientific\u002Fscikit-bio",0,"https:\u002F\u002Fgithub.com\u002FYYC-Cube\u002FYYC3-Knowledge-Base","https:\u002F\u002Fkb.yyc3.top\u002F","https:\u002F\u002Fgithub.com\u002FYYC-Cube","万象归元于云枢 | 深栈智启新纪元","2026-11-10 10:37:32",{"source":8,"skillName":5,"commands":34,"prompt":44,"zipAvailable":45},[35,38,41],{"tool":36,"command":37},"npx","npx skills add YYC-Cube\u002FYYC3-Knowledge-Base --skill scikit-bio",{"tool":39,"command":40},"bunx","bunx skills add YYC-Cube\u002FYYC3-Knowledge-Base --skill scikit-bio",{"tool":42,"command":43},"pnpm","pnpm dlx skills add YYC-Cube\u002FYYC3-Knowledge-Base --skill scikit-bio","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FYYC-Cube\u002FYYC3-Knowledge-Base\u002Fblob\u002Fmain\u002FYYC3-AI-应用工具\u002FYYC3-AI-应用工具-claude-code-templates-main\u002Fcli-tool\u002Fcomponents\u002Fskills\u002Fscientific\u002Fscikit-bio\u002FSKILL.md",true,[47],{"path":48,"resourceType":49,"resourceTypeDesc":50,"sizeBytes":51,"sourceHtmlUrl":52},"references\u002Fapi_reference.md","REFERENCE","参考文档",18564,"https:\u002F\u002Fgithub.com\u002FYYC-Cube\u002FYYC3-Knowledge-Base\u002Fblob\u002Fmain\u002FYYC3-AI-应用工具\u002FYYC3-AI-应用工具-claude-code-templates-main\u002Fcli-tool\u002Fcomponents\u002Fskills\u002Fscientific\u002Fscikit-bio\u002Freferences\u002Fapi_reference.md",[54,61,68,75,82,89],{"skillNo":55,"name":56,"nameZh":6,"description":57,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":58,"categories":59,"keywords":60,"publishedAt":19},"01M7CTDWHERCXPQCP0K03A86AS","vercel-sandbox","Run agent-browser + Chrome inside Vercel Sandbox microVMs for browser automation from any Vercel-deployed app. Use when the user needs browser automation in a Vercel app (Next.js, SvelteKit, Nuxt, Remix, Astro, etc.), wants to run headless Chrome without binary size limits, needs persistent browser sessions across commands, or wants ephemeral isolated browser environments. Triggers include \"Vercel Sandbox browser\", \"microVM Chrome\", \"agent-browser in sandbox\", \"browser automation on Vercel\", or any task requiring Chrome in a Vercel Sandbox.","https:\u002F\u002Fgithub.com\u002FYYC-Cube\u002FYYC3-Knowledge-Base\u002Fblob\u002Fmain\u002FYYC3-WebSpec-Web标准\u002FYYC3-WebSpec-Web标准-standards\u002Fbrowser-agent\u002Fskills\u002Fvercel-sandbox\u002FSKILL.md",[],[],{"skillNo":62,"name":63,"nameZh":6,"description":64,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":65,"categories":66,"keywords":67,"publishedAt":19},"01M7CTD8D2BNJY54S65M47HEJA","slack","Interact with Slack workspaces using browser automation. Use when the user needs to check unread channels, navigate Slack, send messages, extract data, find information, search conversations, or automate any Slack task. Triggers include \"check my Slack\", \"what channels have unreads\", \"send a message to\", \"search Slack for\", \"extract from Slack\", \"find who said\", or any task requiring programmatic Slack interaction.","https:\u002F\u002Fgithub.com\u002FYYC-Cube\u002FYYC3-Knowledge-Base\u002Fblob\u002Fmain\u002FYYC3-WebSpec-Web标准\u002FYYC3-WebSpec-Web标准-standards\u002Fbrowser-agent\u002Fskills\u002Fslack\u002FSKILL.md",[],[],{"skillNo":69,"name":70,"nameZh":6,"description":71,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":72,"categories":73,"keywords":74,"publishedAt":19},"01M7CTCSSB8ZP3Q58C3YZDZK1W","electron","Automate Electron desktop apps (VS Code, Slack, Discord, Figma, Notion, Spotify, etc.) using agent-browser via Chrome DevTools Protocol. Use when the user needs to interact with an Electron app, automate a desktop app, connect to a running app, control a native app, or test an Electron application. Triggers include \"automate Slack app\", \"control VS Code\", \"interact with Discord app\", \"test this Electron app\", \"connect to desktop app\", or any task requiring automation of a native Electron application.","https:\u002F\u002Fgithub.com\u002FYYC-Cube\u002FYYC3-Knowledge-Base\u002Fblob\u002Fmain\u002FYYC3-WebSpec-Web标准\u002FYYC3-WebSpec-Web标准-standards\u002Fbrowser-agent\u002Fskills\u002Felectron\u002FSKILL.md",[],[],{"skillNo":76,"name":77,"nameZh":6,"description":78,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":79,"categories":80,"keywords":81,"publishedAt":19},"01M7CTCBJY76688V4DCZGWFHGQ","dogfood","Systematically explore and test a web application to find bugs, UX issues, and other problems. Use when asked to \"dogfood\", \"QA\", \"exploratory test\", \"find issues\", \"bug hunt\", \"test this app\u002Fsite\u002Fplatform\", or review the quality of a web application. Produces a structured report with full reproduction evidence -- step-by-step screenshots, repro videos, and detailed repro steps for every issue -- so findings can be handed directly to the responsible teams.","https:\u002F\u002Fgithub.com\u002FYYC-Cube\u002FYYC3-Knowledge-Base\u002Fblob\u002Fmain\u002FYYC3-WebSpec-Web标准\u002FYYC3-WebSpec-Web标准-standards\u002Fbrowser-agent\u002Fskills\u002Fdogfood\u002FSKILL.md",[],[],{"skillNo":83,"name":84,"nameZh":6,"description":85,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":86,"categories":87,"keywords":88,"publishedAt":19},"01M7CTC4H0FFGVEAQR9PA4GA1A","agent-browser","Browser automation CLI for AI agents. Use when the user needs to interact with websites, including navigating pages, filling forms, clicking buttons, taking screenshots, extracting data, testing web apps, or automating any browser task. Triggers include requests to \"open a website\", \"fill out a form\", \"click a button\", \"take a screenshot\", \"scrape data from a page\", \"test this web app\", \"login to a site\", \"automate browser actions\", or any task requiring programmatic web interaction.","https:\u002F\u002Fgithub.com\u002FYYC-Cube\u002FYYC3-Knowledge-Base\u002Fblob\u002Fmain\u002FYYC3-WebSpec-Web标准\u002FYYC3-WebSpec-Web标准-standards\u002Fbrowser-agent\u002Fskills\u002Fagent-browser\u002FSKILL.md",[],[],{"skillNo":90,"name":91,"nameZh":6,"description":92,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":93,"categories":94,"keywords":95,"publishedAt":19},"01M7CTBKVFYBG78FDSABSDJTTQ","shadcn","Manages shadcn components and projects — adding, searching, fixing, debugging, styling, and composing UI, including chat interfaces. Provides project context, component docs, and usage examples. Applies when working with shadcn\u002Fui, component registries, presets, --preset codes, or any project with a components.json file. Also triggers for \"shadcn init\", \"create an app with --preset\", \"switch to --preset\", and for building a design system or applying a DESIGN.md or brand spec to shadcn\u002Fui.","https:\u002F\u002Fgithub.com\u002FYYC-Cube\u002FYYC3-Knowledge-Base\u002Fblob\u002Fmain\u002FYYC3-UI-界面组件\u002FYYC3-UI-界面组件-ui\u002Fskills\u002Fshadcn\u002FSKILL.md",[],[]]