mirror of
https://github.com/echemdata/galvani.git
synced 2025-12-14 01:15:34 +00:00
Merge pull request #103 from echemdata/ml-evs/preparing-release
Refresh README in preparation for release
This commit is contained in:
53
README.md
53
README.md
@@ -7,21 +7,60 @@ SPDX-FileCopyrightText: 2013-2020 Christopher Kerr, Peter Attia
|
|||||||
SPDX-License-Identifier: GPL-3.0-or-later
|
SPDX-License-Identifier: GPL-3.0-or-later
|
||||||
-->
|
-->
|
||||||
|
|
||||||
Read proprietary file formats from electrochemical test stations
|
Read proprietary file formats from electrochemical test stations.
|
||||||
|
|
||||||
## Bio-Logic .mpr files ##
|
# Usage
|
||||||
|
|
||||||
|
## Bio-Logic .mpr files
|
||||||
|
|
||||||
Use the `MPRfile` class from BioLogic.py (exported in the main package)
|
Use the `MPRfile` class from BioLogic.py (exported in the main package)
|
||||||
|
|
||||||
````
|
```python
|
||||||
from galvani import BioLogic
|
from galvani import BioLogic
|
||||||
import pandas as pd
|
import pandas as pd
|
||||||
|
|
||||||
mpr_file = BioLogic.MPRfile('test.mpr')
|
mpr_file = BioLogic.MPRfile('test.mpr')
|
||||||
df = pd.DataFrame(mpr_file.data)
|
df = pd.DataFrame(mpr_file.data)
|
||||||
````
|
```
|
||||||
|
|
||||||
## Arbin .res files ##
|
## Arbin .res files
|
||||||
|
|
||||||
Use the res2sqlite.py script to convert the .res file to a sqlite3 database
|
Use the `./galvani/res2sqlite.py` script to convert the .res file to a sqlite3 database with the same schema, which can then be interrogated with external tools or directly in Python.
|
||||||
with the same schema.
|
For example, to extract the data into a pandas DataFrame (will need to be installed separately):
|
||||||
|
|
||||||
|
```python
|
||||||
|
import sqlite3
|
||||||
|
import pandas as pd
|
||||||
|
from galvani.res2sqlite import convert_arbin_to_sqlite
|
||||||
|
convert_arbin_to_sqlite("input.res", "output.sqlite")
|
||||||
|
with sqlite3.connect("output.sqlite") as db:
|
||||||
|
df = pd.read_sql(sql="select * from Channel_Normal_Table", con=db)
|
||||||
|
```
|
||||||
|
|
||||||
|
This functionality requires [MDBTools](https://github.com/mdbtools/mdbtools) to be installed on the local system.
|
||||||
|
|
||||||
|
# Installation
|
||||||
|
|
||||||
|
The latest galvani releases can be installed from [PyPI](https://pypi.org/project/galvani/) via
|
||||||
|
|
||||||
|
```shell
|
||||||
|
pip install galvani
|
||||||
|
```
|
||||||
|
|
||||||
|
The latest development version can be installed with `pip` directly from GitHub:
|
||||||
|
|
||||||
|
```shell
|
||||||
|
pip install git+https://github.com/echemdata/galvani
|
||||||
|
```
|
||||||
|
|
||||||
|
## Development installation and contributing
|
||||||
|
|
||||||
|
If you wish to contribute to galvani, please clone the repository and install the testing dependencies:
|
||||||
|
|
||||||
|
```shell
|
||||||
|
git clone git@github.com:echemdata/galvani
|
||||||
|
cd galvani
|
||||||
|
pip install -e .\[tests\]
|
||||||
|
```
|
||||||
|
|
||||||
|
Code can be contributed back via [GitHub pull requests](https://github.com/echemdata/galvani/pulls) and new features or bugs can be discussed in the [issue tracker](https://github.com/echemdata/galvani/issues).
|
||||||
|
|||||||
Reference in New Issue
Block a user