A Python package for MALDI and LCMS data matching.
Project description
pepBridge
Easy way to match MALDI-MSI (m/z) peaks to the peptides (m/z) from LC-MS/MS
Features
pepBridge is a Python package for processing and matching MALDI and LCMS mass spectrometry data.
- Load MALDI and LCMS data from configuration files and CSVs.
- Match MALDI masses with LCMS masses within a specified tolerance.
- Output matched data to CSV.
Installation
The easiest way to work with pepBridge is by using Anaconda and configuring a virtual environment. Anaconda is a Python distribution plus a packaging manager called conda.
a. Create and configure a virtual environment
conda create --name pepBridge python=3.9
c. Activate the new virtual environment
conda activate pepBridge
d. Install pepBridge package
pip install pepBridge
or
pip install -i https://test.pypi.org/simple/ pepBridge
Usage
(pepBridge)$ pepbridge --help
usage: pepbridge [-h] [--maldi MALDI] [--lcms LCMS] [--mass MASS] [--output OUTPUT] [--version]
Easy way to match MALDI-MSI (m/z) peaks to the peptides (m/z) from LC-MS/MS
optional arguments:
-h, --help show this help message and exit
--maldi MALDI location of the MALDI INI file.
--lcms LCMS location of the LCMS INI file.
--mass MASS Mass tolerance in Da (float number) (default=1.0 Da)
--output OUTPUT Output file in CSV format.
--version Show the version of pepBridge.
Running pepbridge
python pepbridge --maldi maldi.ini --lcms lcms.ini --mass 1.0 --output matched_results_1.0.csv
pepBridge requires two configuration files to run properly. By defaut the names of the files
are maldi.ini and lcms.ini. Basic *.ini files can be copied to the current workign directory typing
(pepBridge) C:\Users>copy_data
The above command copy lcms.ini, maldi.ini and two csv files in the current working directory.
IMS199_OTD196_GK_Thymus_ChemoL_v_CtrlR_MALDI_Match_LCMS_wTrypsinR05_4K_Oct2024_LCMS.csv
IMS199_OTD196_GK_Thymus_ChemoL_v_CtrlR_MALDI_Match_LCMS_wTrypsinR05_4K_Oct2024_MALDI.csv
lcms.ini and maldi.ini are text files consisting of key-value pairs of properties, and sections that organize the properties. lcms.ini/maldi.ini consist in seven sections; [file], [ms_level], [round_mz], [mz_column_name], [verbose], [column_names], [order_columns].
## maldi.ini file
[file]
; Specify the full file path of the MALDI CSV file that contains your data.
; This file is used as input for comparison with LCMS data.
name=/home/cmadrid/DATA/199-196/4K/IMS199_OTD196_GK_Thymus_ChemoL_v_CtrlR_MALDI_Match_LCMS_4K_MALDI.csv
[round_mz]
; Determine whether the m/z values should be rounded to the nearest integer
; before comparing them with LCMS data. Set to "True" to round m/z value
value=True
column_name=rounded_mz
[mz_column_name]
; Specify the name of the column that hold the m/z values in the CSV file.
name=${column_names:column1}
[verbose]
; Enable or disable verbose output during the process.
; Set to "True" for detailed logs to help with troubleshooting or
; understanding the process.
value=True
[column_names]
; Define the names of the columns in the MALDI CSV file.
; These column names will be used for data extraction.
column1=m/z
column2=Average
column3=IMS199_Chemo_Left_4K
column4=IMS199_Control_Right_Bottom_4K
column5=IMS199_Control_Right_Top_4K
[order_columns]
; Specify the order in which columns should appear in the output file.
; The columns will be printed in the specified order, with optional
; modifications such as rounded m/z.
column1=${column_names:column1}
column2=${round_mz:column_name}
column3=${column_names:column2}
column4=${column_names:column3}
column5=${column_names:column4}
column6=${column_names:column5}
lcms.ini file
[file]
; Specify the full file path of the MALDI CSV file that contains your data.
; This file is used as input for comparison with LCMS data.
name=/home/cmadrid/DATA/withTrypsin/IMS199_OTD196_GK_Thymus_ChemoL_v_CtrlR_MALDI_Match_LCMS_wTrypsinR05_4K_Oct2024_LCMS.csv
[round_mz]
; Determine whether the m/z values should be rounded to the nearest integer
; before comparing them with LCMS data. Set to "True" to round m/z value
value=True
column_name=rounded_mz
[mz_column_name]
; Specify the name of the column that hold the m/z values in the CSV file.
name=${column_names:column1}
[verbose]
; Enable or disable verbose output during the process.
; Set to "True" for detailed logs to help with troubleshooting or
; understanding the process.
value=True
[column_names]
; Define the names of the columns in the MALDI CSV file.
; These column names will be used for data extraction.
column1=Theo. MH+ [Da]
column2=Master Protein Accessions
column3=Master Protein Descriptions
column4=Gene Name
column5=Annotated Sequence
column6=Modifications
column7=196a_Left_1 Chemo
column8=196a_Right_2 - Control
column9=log2 ratio Chemo vs Control
[order_columns]
; Specify the order in which columns should appear in the output file.
; The columns will be printed in the specified order, with optional
; modifications such as rounded m/z.
column1=${column_names:column1}
column2=${round_mz:column_name}
column3=${column_names:column2}
column4=${column_names:column3}
column5=${column_names:column4}
column6=${column_names:column5}
column7=${column_names:column6}
column8=${column_names:column7}
column9=${column_names:column8}
column10=${column_names:column9}
UML Class Diagram
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pepbridge-1.0.41.tar.gz.
File metadata
- Download URL: pepbridge-1.0.41.tar.gz
- Upload date:
- Size: 809.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.0.1 CPython/3.9.20
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0b2c7389a0d665743286835de4215fac09b12d7950583fc58caedb52e118ca39
|
|
| MD5 |
07654765b903682c34379235b16b2588
|
|
| BLAKE2b-256 |
2434363dfb9ea9cbde341d3ad78dbe2bbf158caa5a18cb101a450978fb333203
|
File details
Details for the file pepBridge-1.0.41-py3-none-any.whl.
File metadata
- Download URL: pepBridge-1.0.41-py3-none-any.whl
- Upload date:
- Size: 810.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.0.1 CPython/3.9.20
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
78ff9a6a4d294656ebc1c2924b2ce5a9977ce215247a9e1ebd61630da1668f77
|
|
| MD5 |
5f8f1bc1de1a7fc4f9f355a3df3636b3
|
|
| BLAKE2b-256 |
88db671dbf2aa6fcc9c952a7ad57c4985f0edd8adc0b33734a83369735bb8e15
|