korexo-profile


Namekorexo-profile JSON
Version 0.7 PyPI version JSON
download
home_pagehttps://gitlab.com/dew-waterscience/korexo_profile
SummaryRead KorEXO sonde profile CSV files
upload_time2023-11-30 02:27:13
maintainer
docs_urlNone
authorDEW Water Science (Kent Inverarity)
requires_python
licenseAll rights reserved
keywords science
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # korexo_profile

Read KorEXO sonde profile CSV files.

Full package documentation is on [Read the Docs](https://korexo-profile.readthedocs.io/en/latest/).

## Install

```bash
$ pip install korexo_profile
```
## Usage

KorEXO file straight to a table:

```python
>>> import korexo_profile
>>> data = korexo_profile.read("../tests/example1_full.csv")
>>> df = korexo_profile.convert_datasets_to_df(data["datasets"])
```

Or, for the full set of information:

```python
>>> import korexo_profile
>>> data = korexo_profile.read("../tests/example2.csv")
>>> data.keys()
dict_keys(['metadata', 'datasets', 'dataframe'])
>>> df = data["dataframe"]
>>> df.info()
<class 'pandas.core.frame.DataFrame'>
RangeIndex: 9 entries, 0 to 8
Data columns (total 22 columns):
 #   Column               Non-Null Count  Dtype
---  ------               --------------  -----
 0   Date (MM/DD/YYYY)    9 non-null      object
 1   Time (HH:mm:ss)      9 non-null      object
 2   Time (Fract. Sec)    9 non-null      int64
 3   Site Name            9 non-null      object
 4   Cond µS/cm           9 non-null      int64
 5   Depth m              9 non-null      float64
 6   nLF Cond µS/cm       9 non-null      float64
 7   ODO % sat            9 non-null      float64
 8   ODO % local          9 non-null      float64
 9   ODO mg/L             9 non-null      float64
 10  ORP mV               9 non-null      float64
 11  Pressure psi a       9 non-null      float64
 12  Sal psu              9 non-null      int64
 13  SpCond µS/cm         9 non-null      float64
 14  TDS mg/L             9 non-null      int64
 15  pH                   9 non-null      float64
 16  pH mV                9 non-null      float64
 17  Temp °C              9 non-null      float64
 18  Vertical Position m  9 non-null      float64
 19  Battery V            9 non-null      float64
 20  Cable Pwr V          9 non-null      float64
 21  DTW                  1 non-null      float64
dtypes: float64(15), int64(4), object(3)
memory usage: 1.7+ KB
```

Or each dataset at a time:

```
>>> data["datasets"][0]
{'name': 'Date',
 'column': 'Date (MM/DD/YYYY)',
 'sensor': '',
 'mean': <NA>,
 'stdev': <NA>,
 'data': [datetime.date(2020, 10, 16),
  datetime.date(2020, 10, 16),
  datetime.date(2020, 10, 16),
  datetime.date(2020, 10, 16),
  datetime.date(2020, 10, 16),
  datetime.date(2020, 10, 16),
  datetime.date(2020, 10, 16),
  datetime.date(2020, 10, 16),
  datetime.date(2020, 10, 16)],
 'median': datetime.date(2020, 10, 16)}
>>> data["datasets"][1]
{'name': 'Time',
 'column': 'Time (HH:mm:ss)',
 'sensor': '',
 'mean': <NA>,
 'stdev': <NA>,
 'data': array(['15:49:33', '15:49:34', '15:49:35', '15:49:36', '15:49:37',
        '15:49:38', '15:49:39', '15:49:40', '15:49:41'], dtype=object),
 'median': '15:49:33'}
>>> data["datasets"][9]
{'name': 'ODO mg/L',
 'column': 'ODO mg/L',
 'sensor': '19D101830',
 'mean': 7.66,
 'stdev': 0.97,
 'data': array([9.5 , 9.5 , 9.49, 9.49, 9.5 , 9.49, 9.49, 9.5 , 9.49]),
 'median': 9.49}
```

And the metadata:

```python
>>> data["metadata"]
{'created_file': datetime.datetime(2022, 4, 7, 16, 45, 10, 874033),
 'modified_file': datetime.datetime(2022, 4, 7, 16, 45, 10, 875029),
 'created_info': '10/16/2020 6:21:53 AM,,,,,,,,,,,,,,,,,,,,',
 'header_line_no': 9,
 'params': ['Cond µS/cm',
  'Depth m',
  'nLF Cond µS/cm',
  'ODO % sat',
  'ODO % local',
  'ODO mg/L',
  'ORP mV',
  'Pressure psi a',
  'Sal psu',
  'SpCond µS/cm',
  'TDS mg/L',
  'pH',
  'pH mV',
  'Temp °C',
  'Vertical Position m',
  'Battery V',
  'Cable Pwr V',
  'DTW'],
 'sensors': ['19A103955',
  '19B104242',
  '19A103955',
  '19D101830',
  '19D101830',
  '19D101830',
  '19B105042',
  '19B104242',
  '19A103955',
  '19A103955',
  '19A103955',
  '19B105042',
  '19B105042',
  '19A103955',
  '19B104242',
  '19C000969',
  '19C000969',
  ''],
 'means': [1172.5,
  0.605,
  1277.2,
  85.5,
  85.6,
  7.66,
  47.1,
  0.859,
  0.64,
  1268.1,
  824,
  <NA>,
  -126,
  20.679,
  0.812,
  3.13,
  11.4,
  nan],
 'stdevs': [566.7,
  0.791,
  617.1,
  9.2,
  9.2,
  0.97,
  1.1,
  1.123,
  0.31,
  612.7,
  398,
  0.1,
  5.7,
  0.8,
  0.972,
  0,
  0,
  nan]}
```

Full package documentation is on [Read the Docs](https://korexo-profile.readthedocs.io/en/latest/).

            

Raw data

            {
    "_id": null,
    "home_page": "https://gitlab.com/dew-waterscience/korexo_profile",
    "name": "korexo-profile",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "science",
    "author": "DEW Water Science (Kent Inverarity)",
    "author_email": "kent.inverarity@sa.gov.au",
    "download_url": "https://files.pythonhosted.org/packages/f8/70/9b0667148ef7131de99aeb763ba7267efaea2352753282e5289a86fb239d/korexo_profile-0.7.tar.gz",
    "platform": null,
    "description": "# korexo_profile\n\nRead KorEXO sonde profile CSV files.\n\nFull package documentation is on [Read the Docs](https://korexo-profile.readthedocs.io/en/latest/).\n\n## Install\n\n```bash\n$ pip install korexo_profile\n```\n## Usage\n\nKorEXO file straight to a table:\n\n```python\n>>> import korexo_profile\n>>> data = korexo_profile.read(\"../tests/example1_full.csv\")\n>>> df = korexo_profile.convert_datasets_to_df(data[\"datasets\"])\n```\n\nOr, for the full set of information:\n\n```python\n>>> import korexo_profile\n>>> data = korexo_profile.read(\"../tests/example2.csv\")\n>>> data.keys()\ndict_keys(['metadata', 'datasets', 'dataframe'])\n>>> df = data[\"dataframe\"]\n>>> df.info()\n<class 'pandas.core.frame.DataFrame'>\nRangeIndex: 9 entries, 0 to 8\nData columns (total 22 columns):\n #   Column               Non-Null Count  Dtype\n---  ------               --------------  -----\n 0   Date (MM/DD/YYYY)    9 non-null      object\n 1   Time (HH:mm:ss)      9 non-null      object\n 2   Time (Fract. Sec)    9 non-null      int64\n 3   Site Name            9 non-null      object\n 4   Cond \u00b5S/cm           9 non-null      int64\n 5   Depth m              9 non-null      float64\n 6   nLF Cond \u00b5S/cm       9 non-null      float64\n 7   ODO % sat            9 non-null      float64\n 8   ODO % local          9 non-null      float64\n 9   ODO mg/L             9 non-null      float64\n 10  ORP mV               9 non-null      float64\n 11  Pressure psi a       9 non-null      float64\n 12  Sal psu              9 non-null      int64\n 13  SpCond \u00b5S/cm         9 non-null      float64\n 14  TDS mg/L             9 non-null      int64\n 15  pH                   9 non-null      float64\n 16  pH mV                9 non-null      float64\n 17  Temp \u00b0C              9 non-null      float64\n 18  Vertical Position m  9 non-null      float64\n 19  Battery V            9 non-null      float64\n 20  Cable Pwr V          9 non-null      float64\n 21  DTW                  1 non-null      float64\ndtypes: float64(15), int64(4), object(3)\nmemory usage: 1.7+ KB\n```\n\nOr each dataset at a time:\n\n```\n>>> data[\"datasets\"][0]\n{'name': 'Date',\n 'column': 'Date (MM/DD/YYYY)',\n 'sensor': '',\n 'mean': <NA>,\n 'stdev': <NA>,\n 'data': [datetime.date(2020, 10, 16),\n  datetime.date(2020, 10, 16),\n  datetime.date(2020, 10, 16),\n  datetime.date(2020, 10, 16),\n  datetime.date(2020, 10, 16),\n  datetime.date(2020, 10, 16),\n  datetime.date(2020, 10, 16),\n  datetime.date(2020, 10, 16),\n  datetime.date(2020, 10, 16)],\n 'median': datetime.date(2020, 10, 16)}\n>>> data[\"datasets\"][1]\n{'name': 'Time',\n 'column': 'Time (HH:mm:ss)',\n 'sensor': '',\n 'mean': <NA>,\n 'stdev': <NA>,\n 'data': array(['15:49:33', '15:49:34', '15:49:35', '15:49:36', '15:49:37',\n        '15:49:38', '15:49:39', '15:49:40', '15:49:41'], dtype=object),\n 'median': '15:49:33'}\n>>> data[\"datasets\"][9]\n{'name': 'ODO mg/L',\n 'column': 'ODO mg/L',\n 'sensor': '19D101830',\n 'mean': 7.66,\n 'stdev': 0.97,\n 'data': array([9.5 , 9.5 , 9.49, 9.49, 9.5 , 9.49, 9.49, 9.5 , 9.49]),\n 'median': 9.49}\n```\n\nAnd the metadata:\n\n```python\n>>> data[\"metadata\"]\n{'created_file': datetime.datetime(2022, 4, 7, 16, 45, 10, 874033),\n 'modified_file': datetime.datetime(2022, 4, 7, 16, 45, 10, 875029),\n 'created_info': '10/16/2020 6:21:53 AM,,,,,,,,,,,,,,,,,,,,',\n 'header_line_no': 9,\n 'params': ['Cond \u00b5S/cm',\n  'Depth m',\n  'nLF Cond \u00b5S/cm',\n  'ODO % sat',\n  'ODO % local',\n  'ODO mg/L',\n  'ORP mV',\n  'Pressure psi a',\n  'Sal psu',\n  'SpCond \u00b5S/cm',\n  'TDS mg/L',\n  'pH',\n  'pH mV',\n  'Temp \u00b0C',\n  'Vertical Position m',\n  'Battery V',\n  'Cable Pwr V',\n  'DTW'],\n 'sensors': ['19A103955',\n  '19B104242',\n  '19A103955',\n  '19D101830',\n  '19D101830',\n  '19D101830',\n  '19B105042',\n  '19B104242',\n  '19A103955',\n  '19A103955',\n  '19A103955',\n  '19B105042',\n  '19B105042',\n  '19A103955',\n  '19B104242',\n  '19C000969',\n  '19C000969',\n  ''],\n 'means': [1172.5,\n  0.605,\n  1277.2,\n  85.5,\n  85.6,\n  7.66,\n  47.1,\n  0.859,\n  0.64,\n  1268.1,\n  824,\n  <NA>,\n  -126,\n  20.679,\n  0.812,\n  3.13,\n  11.4,\n  nan],\n 'stdevs': [566.7,\n  0.791,\n  617.1,\n  9.2,\n  9.2,\n  0.97,\n  1.1,\n  1.123,\n  0.31,\n  612.7,\n  398,\n  0.1,\n  5.7,\n  0.8,\n  0.972,\n  0,\n  0,\n  nan]}\n```\n\nFull package documentation is on [Read the Docs](https://korexo-profile.readthedocs.io/en/latest/).\n",
    "bugtrack_url": null,
    "license": "All rights reserved",
    "summary": "Read KorEXO sonde profile CSV files",
    "version": "0.7",
    "project_urls": {
        "Homepage": "https://gitlab.com/dew-waterscience/korexo_profile"
    },
    "split_keywords": [
        "science"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "3262be51ef971df21f0b8107569a4d48d1450928bf9b66df2ef93bd59b21e1ca",
                "md5": "ad84ee008ac61b2f7ce8f39c12e39355",
                "sha256": "66ad474160aab453938eaec44a6fed5b16629b79c270ebbb837ac9bda2dce36a"
            },
            "downloads": -1,
            "filename": "korexo_profile-0.7-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "ad84ee008ac61b2f7ce8f39c12e39355",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 7221,
            "upload_time": "2023-11-30T02:27:12",
            "upload_time_iso_8601": "2023-11-30T02:27:12.186757Z",
            "url": "https://files.pythonhosted.org/packages/32/62/be51ef971df21f0b8107569a4d48d1450928bf9b66df2ef93bd59b21e1ca/korexo_profile-0.7-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f8709b0667148ef7131de99aeb763ba7267efaea2352753282e5289a86fb239d",
                "md5": "94f4e875bd80aecbefedb5561ad93ced",
                "sha256": "a1fdf849b4688a585e8a14b66ebd3c2cb50724b8cc502dbe58bce4c596295731"
            },
            "downloads": -1,
            "filename": "korexo_profile-0.7.tar.gz",
            "has_sig": false,
            "md5_digest": "94f4e875bd80aecbefedb5561ad93ced",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 23337,
            "upload_time": "2023-11-30T02:27:13",
            "upload_time_iso_8601": "2023-11-30T02:27:13.649969Z",
            "url": "https://files.pythonhosted.org/packages/f8/70/9b0667148ef7131de99aeb763ba7267efaea2352753282e5289a86fb239d/korexo_profile-0.7.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-11-30 02:27:13",
    "github": false,
    "gitlab": true,
    "bitbucket": false,
    "codeberg": false,
    "gitlab_user": "dew-waterscience",
    "gitlab_project": "korexo_profile",
    "lcname": "korexo-profile"
}
        
Elapsed time: 2.29880s