{"id":16554399,"url":"https://github.com/foggalong/robustocs","last_synced_at":"2025-09-10T04:13:06.394Z","repository":{"id":248135419,"uuid":"760469806","full_name":"Foggalong/RobustOCS","owner":"Foggalong","description":"Robust optimal contirbution selection problems for genetics with Python","archived":false,"fork":false,"pushed_at":"2024-08-09T14:04:00.000Z","size":10465,"stargazers_count":1,"open_issues_count":3,"forks_count":0,"subscribers_count":4,"default_branch":"main","last_synced_at":"2024-08-09T16:23:35.951Z","etag":null,"topics":["breeding","genomic-selection","genomics","python","python-module","selective-breeding"],"latest_commit_sha":null,"homepage":"https://pypi.org/project/robustocs","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Foggalong.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":".github/CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":".github/CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":".github/SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-02-20T13:34:30.000Z","updated_at":"2024-08-09T14:04:03.000Z","dependencies_parsed_at":"2024-08-06T16:08:29.567Z","dependency_job_id":null,"html_url":"https://github.com/Foggalong/RobustOCS","commit_stats":null,"previous_names":["foggalong/robustocs"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Foggalong%2FRobustOCS","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Foggalong%2FRobustOCS/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Foggalong%2FRobustOCS/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Foggalong%2FRobustOCS/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Foggalong","download_url":"https://codeload.github.com/Foggalong/RobustOCS/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":219858948,"owners_count":16556039,"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","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":["breeding","genomic-selection","genomics","python","python-module","selective-breeding"],"created_at":"2024-10-11T19:51:23.278Z","updated_at":"2024-10-11T19:51:23.944Z","avatar_url":"https://github.com/Foggalong.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# RobustOCS\n\n[![PyPi](https://img.shields.io/pypi/v/robustocs.svg)](https://pypi.python.org/pypi/robustocs) [![Check Build](https://github.com/Foggalong/RobustOCS/actions/workflows/check-build.yml/badge.svg?branch=main)](https://github.com/Foggalong/RobustOCS/actions/workflows/check-build.yml)\n\nTools for solving robust optimal contribution selection problems in Python. All code and examples in RobustOCS are fully and freely available for all use under the MIT License.\n\n## Installation\n\nThe latest release can be installed from the [PyPI repository](https://pypi.org/project/robustocs/) using\n\n```bash\npip install robustocs\n```\n\nAlternatively, it use the latest (potentially unstable) version from GitHub, use\n\n```bash\ngit clone https://github.com/Foggalong/RobustOCS.git\npip install RobustOCS/\n```\n\nEither way, the package depends on Python 3.10+, using [NumPy](https://pypi.org/project/numpy) for linear algebra and [SciPy](https://scipy.org) for sparse matrix objects. As a solver it can either use [Gurobi](https://www.gurobi.com) (commercial) via [gurobipy](https://pypi.org/project/gurobipy) or [HiGHS](https://highs.dev) (free software) via [highspy](https://pypi.org/project/highspy).\n\n## Quick-start\n\nSuppose we have a breeding cohort whose relationships are modelled some matrix $\\Sigma$, and whose expected breeding values have mean $\\bar{\\boldsymbol\\mu}$ and variance $\\Omega$. If these are [saved in files](https://github.com/Foggalong/RobustOCS/wiki/File-Formats), finding the robust optimal contribution selection is as simple as opening Python and running\n\n```python\nimport robustocs as rocs\n\nselection, objective, merit, coancestry = rocs.solveROCS(\n    sigma_filename=\"cohort-relationships.txt\",\n    mu_filename=\"breeding-means.txt\",\n    omega_filename=\"breeding-variances.txt\",\n    sex_filename=\"cohort-sexes.txt\",\n    method='robust', lam=0.5, kappa=1\n)\n```\n\nwhere `selection` will be an array of optimal selections, `objective` is a score of the selection, `merit` the expected genetic merit, and `coancestry` the group co-ancestry.\n\n## Documentation\n\nThe [GitHub wiki] includes documentation which explains the usage and parameters in more detail, full rundowns of the key functions (including the quick-start's [`solveROCS`]), all alongside some worked examples using the more granular solver functions (the data for which is in [`examples/`](examples/)). This includes a realistic simulated example from [Gregor Gorjanc] and [Ivan Pocrnić].\n\n[`solveROCS`]: https://github.com/Foggalong/RobustOCS/wiki/solveROCS\n[GitHub wiki]: https://github.com/Foggalong/RobustOCS/wiki\n[Gregor Gorjanc]: https://www.ed.ac.uk/profile/gregor-gorjanc\n[Ivan Pocrnić]: https://www.ed.ac.uk/profile/ivan-pocrnic\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffoggalong%2Frobustocs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffoggalong%2Frobustocs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffoggalong%2Frobustocs/lists"}