Giter Site home page Giter Site logo

pgomes92 / kubios Goto Github PK

View Code? Open in Web Editor NEW
9.0 0.0 3.0 23 KB

Python package to export NN/RR interval series in KUBIOS HRV readable format and to import HRV results from KUBIOS report files in .txt format.

License: BSD 3-Clause "New" or "Revised" License

Python 100.00%

kubios's Introduction

KUBIOS Import & Export for Python

This Python package enables easy exportation of NN/RR interval series or signals to KUBIOS HRV friendly files and structured formats and to import HRV analysis results from KUBIOS HRV report files in .txt format.

The exported signals are stored in the Type 1 format as presented on page 14 and 15 of the KUBIOS User Guide.

Installation

This package can be installed using the pip tool:

pip install kubios

How to Use this Package

export_nni()

Use the export_nni() function to export a series of NN/RR interval or ECG signal data to a KUBIOS readable file format.

import numpy as np
from kubios import export_nni

# Load NNI series
nni = np.load('SampleSeries.npy')

# Export NNI series
export_nni(nni)

Use the output_path variable to specify the file path where to store the exported file and output_file to specify the file name. Use only the output_file if you want to set the absolute file path in a single string. If no value for the output_file is provided, a file name (incl. time stamp) will automatically be generated.

import numpy as np
from kubios import export_nni

# Load NNI series
nni = np.load('SampleSeries.npy')

# Export NNI series with specific file name
export_nni(nni, output_file='export.txt)

# Export NNI series to specific path & specific file name
export_nni(nni, output_path='/my/favorite/path/', output_file='export.txt')

# Export NNI series to specific path with automatic file name generation
export_nni(nni, output_path='/my/favorite/path/')

import_report()

Use the import_report() function to read a KUBIOS HRV report files in .txt format. The results will be returned in a Python dictionary.

from kubios import import_report

# Import HRV results from KUBIOS report
results = import_report('SampleReport.txt')

# Get SDNN value
results['sdnn']

Dependencies

Context of this Work

This package is under development within the scope of my master thesis "Development of an Open-Source Python Toolbox for Heart Rate Variability (HRV)" at the University of Applied Sciences Hamburg, Germany (Faculty Life Sciences, Department of Biomedical Engineering) and PLUX wireless biosignals, S.A., Lisbon, Portugal.

Disclaimer

This package is not part of the official KUBIOS software.

This program is distributed in the hope it will be useful and provided to you "as is", but WITHOUT ANY WARRANTY, without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. This program is NOT intended for medical diagnosis. We expressly disclaim any liability whatsoever for any direct, indirect, consequential, incidental or special damages, including, without limitation, lost revenues, lost profits, losses resulting from business interruption or loss of data, regardless of the form of action or legal theory under which the liability may be asserted, even if advised of the possibility of such damages.

kubios's People

Contributors

pgomes92 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Forkers

noah10 jiehawes

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.