{"id":15555231,"url":"https://github.com/brews/co2syspy","last_synced_at":"2026-02-02T15:05:45.971Z","repository":{"id":62563181,"uuid":"120811923","full_name":"brews/co2syspy","owner":"brews","description":"A Python interpretation of CO2SYS","archived":false,"fork":false,"pushed_at":"2020-02-04T07:27:48.000Z","size":48,"stargazers_count":3,"open_issues_count":6,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-06-10T04:41:36.260Z","etag":null,"topics":["chemistry","co2","python","seawater"],"latest_commit_sha":null,"homepage":"","language":"Python","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/brews.png","metadata":{"files":{"readme":"README.md","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}},"created_at":"2018-02-08T20:09:06.000Z","updated_at":"2023-06-29T21:02:18.000Z","dependencies_parsed_at":"2022-11-03T15:45:28.975Z","dependency_job_id":null,"html_url":"https://github.com/brews/co2syspy","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/brews/co2syspy","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brews%2Fco2syspy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brews%2Fco2syspy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brews%2Fco2syspy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brews%2Fco2syspy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/brews","download_url":"https://codeload.github.com/brews/co2syspy/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brews%2Fco2syspy/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259293153,"owners_count":22835547,"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":["chemistry","co2","python","seawater"],"created_at":"2024-10-02T15:07:26.833Z","updated_at":"2026-02-02T15:05:45.938Z","avatar_url":"https://github.com/brews.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# co2syspy\n\n[![Travis-CI Build Status](https://travis-ci.org/brews/co2syspy.svg?branch=master)](https://travis-ci.org/brews/co2syspy)\n[![Coverage Status](https://coveralls.io/repos/github/brews/co2syspy/badge.svg?branch=master)](https://coveralls.io/github/brews/co2syspy?branch=coverage_fix)\n\nA Python interpretation of CO2SYS (http://cdiac.ess-dive.lbl.gov/ftp/co2sys/).\n\nThis package is not stable, nor fully tested. It is also not very pythonic.\n\n## Example\n\nFirst, import the package:\n\n```python\nimport co2sys\n```\n    \nUse the old-school interface with `co2sys.CO2SYS()`. First, lets setup some variables to input:\n\n```python\npar1type = 1  # The first parameter supplied is of type \"1\", which is \"alkalinity\"\npar2type = 2  # The first parameter supplied is of type \"2\", which is \"DIC\"\npar3type = 3  # The first parameter supplied is of type \"3\", which is \"pH\"\npresin   = 4.036785269144779e3  # Pressure at input conditions\ntempout  = 0  # Temperature at output conditions.\npresout  = 0  # Pressure    at output conditions.\npHscale  = 1  # pH scale at which the input pH is reported (\"1\" means \"Total Scale\")\nk1k2c    = 4  # Choice of H2CO3 and HCO3- dissociation constants K1 and K2 (\"4\" means \"Mehrbach refit\")\nkso4c    = 1  # Choice of HSO4- dissociation constants KSO4 (\"1\" means \"Dickson\")\nalk_s  = 2.337701660156250e3\ndic_s  = 2.186364257812500e3\nsal_s  = 34.875812530517578\ntemp_s = 2.197510004043579\nsi_s   = 49.758834838867188\np_s    = 1.458118438720703\n```\n\nNow, take all of this and run with it:\n\n```python\nout, niceheaders = co2sys.CO2SYS(alk_s, dic_s, par1type, par2type, sal_s, \n                                 temp_s, tempout, presin, presout, si_s, \n                                 p_s, pHscale, k1k2c, kso4c)\n```\n\nOur output system variables are now held in `out` and the traditional CO2SYS \"nice headers\" are in `niceheaders`.\n\n## Installation\n\nInstall `co2syspy` from `conda` with:\n\n```bash\nconda install co2syspy -c sbmalev\n```\n\nInstall with `pip` using:\n\n```bash\npip install co2syspy\n```    \n\n## Support and development\n\n* Please feel free to report bugs and issues, or view the source code on GitHub (https://github.com/brews/co2syspy).\n\n## License\n\n`co2syspy` is available under the Open Source GPLv3 (https://www.gnu.org/licenses).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbrews%2Fco2syspy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbrews%2Fco2syspy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbrews%2Fco2syspy/lists"}