{"id":32554187,"url":"https://github.com/noriakis/stana","last_synced_at":"2025-10-28T21:57:47.710Z","repository":{"id":111852153,"uuid":"581533805","full_name":"noriakis/stana","owner":"noriakis","description":"Metagenotyping analysis in R","archived":false,"fork":false,"pushed_at":"2024-04-13T04:28:45.000Z","size":5909,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-04-13T18:11:10.663Z","etag":null,"topics":["intra-species","metagenomics","metagenotyping","microbiome","r","strain-analysis"],"latest_commit_sha":null,"homepage":"https://noriakis.github.io/software/stana","language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/noriakis.png","metadata":{"files":{"readme":"README.Rmd","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2022-12-23T13:21:25.000Z","updated_at":"2024-04-15T13:47:42.103Z","dependencies_parsed_at":"2024-04-15T13:47:32.084Z","dependency_job_id":null,"html_url":"https://github.com/noriakis/stana","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/noriakis/stana","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/noriakis%2Fstana","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/noriakis%2Fstana/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/noriakis%2Fstana/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/noriakis%2Fstana/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/noriakis","download_url":"https://codeload.github.com/noriakis/stana/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/noriakis%2Fstana/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":281520716,"owners_count":26515681,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-28T02:00:06.022Z","response_time":60,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["intra-species","metagenomics","metagenotyping","microbiome","r","strain-analysis"],"created_at":"2025-10-28T21:57:46.728Z","updated_at":"2025-10-28T21:57:47.705Z","avatar_url":"https://github.com/noriakis.png","language":"R","funding_links":[],"categories":[],"sub_categories":[],"readme":"---\noutput: github_document\n---\n\n\u003c!-- README.md is generated from README.Rmd. Please edit that file --\u003e\n\n```{r setup, include = FALSE}\nknitr::opts_chunk$set(\n  collapse = TRUE,\n  comment = \"#\u003e\",\n  fig.path = \"man/figures/README-\",\n  fig.dev = \"grDevices::png\",\n  dpi = 300L,\n  dev.args = list(),\n  fig.ext = \"png\",\n  fig.height=8,\n  fig.width=12,\n  fig.retina = 2L,\n  fig.align = \"center\"\n)\n```\n\n# stana\n\n\u003c!-- badges: start --\u003e\n[![R-CMD-check](https://github.com/noriakis/stana/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/noriakis/stana/actions/workflows/R-CMD-check.yaml)\n\u003c!-- badges: end --\u003e\n\nMetagenotyping analysis in R. Import and analyse, visualize the metagenotyping output of the software like [MIDAS](https://github.com/snayfach/MIDAS), [MIDAS2](https://github.com/czbiohub/MIDAS2), [metaSNV and metaSNV v2](https://github.com/metasnv-tool/metaSNV), and [inStrain](https://github.com/MrOlm/inStrain). In general the metagenotyping software produces the allelic count information and gene copy number tables and the package utilizes these information to analyze the intra-species diversity.\n\nThe detailed usage is available at [https://noriakis.github.io/software/stana](https://noriakis.github.io/software/stana), using `bookdown`.\n\n## Installation\n\nUsing `devtools`:\n\n```{r, eval=FALSE}\ndevtools::install_github(\"noriakis/stana\")\n```\n\n## Pipeline\n\n\u003cimg src=\"https://github.com/noriakis/software/blob/main/images/stana_pipeline.png?raw=true\" width=\"800px\"\u003e\n\n## Examples\n\n```{r message=FALSE, warning=FALSE, fig.width=6, fig.height=6}\n## Using example data\nlibrary(stana)\nlibrary(phangorn)\nload(system.file(\"extdata\", \"sysdata.rda\", package = \"stana\"))\n\nstana\ngetID(stana)\n\n## Make example metadata\nsamples \u003c- getSlot(stana, \"snps\")[[1]] |\u003e colnames()\nmetadata \u003c- data.frame(\n    row.names=samples,\n    treatment=factor(sample(1:3, length(samples), replace=TRUE)),\n    marker=runif(length(samples))\n)\n\n\n## Set metadata\nstana \u003c- setMetadata(stana, metadata)\n\n## Call consensus sequence\n## Infer and plot tree based on metadata\nstana \u003c- stana |\u003e\n  consensusSeq(argList=list(site_prev=0.95)) |\u003e\n  inferAndPlotTree(meta=c(\"treatment\",\"marker\"))\ngetFasta(stana)[[1]]\ngetTree(stana)[[1]]\ngetTreePlot(stana)[[1]]\n```\n\nIf the gene copy number table is available like in `MIDAS` series and `inStrain`, one can compare the functional implications of these gene contents. The details are described in the [documentation](https://noriakis.github.io/software/stana).\n\n\n## Interactive inspection\n\nThe users can inspect metagenotyping results interactively using Shiny based on the variables such as disease conditions (`exportInteractive()`). One can publish the results in the hosting services for sharing the research findings.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnoriakis%2Fstana","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnoriakis%2Fstana","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnoriakis%2Fstana/lists"}