phenomecentre / nPYc-Toolbox

The nPYc-Toolbox defines objects for representing, and implements functions to manipulate and display, metabolic profiling datasets.
MIT License
24 stars 8 forks source link

how to access the actual spectral data for further analysis: normalization/scaling, PCA, PLS, STOCSY, etc. #80

Open RicardoMBorges opened 2 years ago

RicardoMBorges commented 2 years ago

Hello, I have followed you impressive pipeline (which I understood is within QC) successfully, but I wanted to move further into the multivariate side of metabolomics for actual interpretation. Could you clarify somethings for me (I am quite new in Python/Jupyther): how to access the actual spectral data for further analysis: normalization/scaling, PCA, PLS, STOCSY, etc. within the same .ipynb file?

Thank you

Gscorreia89 commented 2 years ago

Hi,

Each nPYc-Toolbox object has an "intensityData" attribute containing the data matrix, which can be accessed using the command nmrData.intensityData.

The order of the rows in "intensityData" and columns in "intensityData" align with the rows in sampleMetadata and featureMetadata attributes, respectively. These can be inspected in the same manner, for e.g. msData.sampleMetadata.

We also provide features for total area and probabilistic quotient normalisation. More instructions are detailed here https://npyc-toolbox.readthedocs.io/en/latest/normalisation.html. When the normalisation option is set up, the intensityData atribute returned is already normalised.

Finally, there is some basic support for multivariate exploratory analysis in the nPYc-Toolbox, but its designed to explore associations between principal components and experimental factors which are parsed from the raw data (i.,e run order, batches, detector voltage, among others). More info is available here in case you want to give it a try: https://npyc-toolbox.readthedocs.io/en/latest/multivariate.html#

Thank you for your interest in giving our tools a try!

RicardoMBorges commented 2 years ago

Great, thanks. So, one possibility is to map this data as a MetaboAnalyst entree file and go through the exploration analysis, right? Or just move forward in the same Notebook adding PLS-DA and STOCSY... Thanjs @Gscorreia89