Skip to main content

cft-analysis

PyPI GitHub Lint Code style: black GitHub commit activity

Python package for the analysis of data collected during the Cold Face Test (CFT) study.

Description

This package contains various helper functions to work with the dataset (including tpcp Dataset representations) and to process data. Additionally, it contains different analysis experiments performed with the dataset.

Repository Structure

The repository is structured as follows:

├── cft_analysis/                                   # cft-analysis Python package
└── experiments/                                    # Folder with conducted analysis experiments; each experiment has its own subfolder
    └── 2022_scientific_reports/                    # Analysis for the 2022 Scientific Reports Paper (see below)
        ├── data/                                   # Processed data and extracted parameters
        ├── notebooks/                              # Notebooks for data processing, analysis and plotting
        │   ├── data_processing/            
        │   │   ├── ECG_Processing_Feature_Computation.ipynb    # Processing and feature extraction from ECG data
        │   │   ├── Questionnaire_Processing.ipynb              # Processing of questionnaire data
        │   │   └── Saliva_Processing.ipynb                     # Processing of saliva data
        │   ├── analysis/                   
        │   │   ├── Subject_Exclusion.ipynb         # Checks whether (and which) subjects need to be excluded from further analysis
        │   │   ├── Demographics.ipynb              # Analysis of general information of study population: Age, Gender, BMI, ...
        │   │   ├── ECG_Analysis.ipynb              # Descriptive and statistical analysis of ECG data
        │   │   ├── Questionnaire_Analysis.ipynb    # Descriptive and statistical analysis of questionnaire data
        │   │   └── Saliva_Analysis.ipynb           # Descriptive and statistical analysis of saliva data
        │   └── plotting/
        ├── results/                                # Plots and statistical results exported by the notebooks in the "analysis" and "plotting" folders
        └── config.json                             # 

Installation

If you want to use this package to reproduce the analysis results then clone the repository and install the package via poetry:

git clone git@github.com:mad-lab-fau/cft-analysis.git
cd cft-analysis
poetry install # alternative: pip install .

This creates a new python venv in the cft-analysis/.venv folder. Next, register a new IPython kernel for the venv:

cd cft-analysis
poetry run poe register_ipykernel

Finally, go to the experiments folder and run the Jupyter Notebooks.

Experiments

Currently, this repository contains the following experiments:

2022 – Scientific Reports

Analysis of the CFT Dataset for the paper Vagus Activation by Cold Face Test Reduces Acute Psychosocial Stress Responses, published in Scientific Reports.

Usage

In order to run the code, first download the CFT Dataset, e.g. from OSF. Then, create a file named config.json in the folder /experiments/2022_scientific_reports with the following content:

{
    "base_path": "<path-to-dataset>"
}

This config file is parsed by all notebooks to extract the path to the dataset.
NOTE: This file is ignored by git because the path to the dataset depends on the local configuration!

The files in the data folder are created by running the notebooks in the data_processing folder. The files in the result folder are created by running the notebooks in the analysis and the plotting folders.

Metadata

Release files for cft-analysis 1.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for cft-analysis 1.2.0
File Size Uploaded Provenance Actions
cft_analysis-1.2.0.tar.gz 13.7 kB Without provenance Details for cft_analysis-1.2.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for cft-analysis 1.2.0
File Interpreter ABI Platform Actions
cft_analysis-1.2.0-py3-none-any.whl Python 3 none any Details for cft_analysis-1.2.0-py3-none-any.whl

Total release size: 29.7 kB

Release files / cft_analysis-1.2.0.tar.gz

Download URL cft_analysis-1.2.0.tar.gz
Size 13.7 kB
Tags Source
SHA-256 checksum
How to use checksums
d5f1b0457c6f6621f04211d8521eac8d96591b5a5619533127157985f75117c7
BLAKE2b-256 checksum
How to use checksums
590cb4e8789d75639e688565201523e12aeb342c5d6c01b155ca7096b7d0bf4e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.3.0 CPython/3.11.0 Linux/5.15.0-1024-azure

Release files / cft_analysis-1.2.0-py3-none-any.whl

Download URL cft_analysis-1.2.0-py3-none-any.whl
Size 16.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b162bc63c72595f5f94daeb308f9df3b1f557e88f8bd920fba4e9f3df0e830e7
BLAKE2b-256 checksum
How to use checksums
7513e3c6ad641aa542a0f2d9f81be6d69b2ef17eabee03ca53aae8b69bc693e0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.3.0 CPython/3.11.0 Linux/5.15.0-1024-azure

Security for cft-analysis 1.2.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page