Skip to content

Commit

Permalink
FIX alphatims_wrapper docs
Browse files Browse the repository at this point in the history
  • Loading branch information
jalew188 committed Jun 26, 2024
1 parent a52aa18 commit 3e3cff0
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions alpharaw/wrappers/alphatims_wrapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

class AlphaTimsReader(MSData_Base):
"""
> TimsTOF data are too large, do not use this class
TimsTOF data are too large, do not use this class
"""

def import_raw(self, burker_d_folder: str):
Expand Down Expand Up @@ -43,8 +43,16 @@ def import_raw(self, burker_d_folder: str):


class AlphaTimsWrapper(TimsTOF):
"""Create a AlphaTims object that contains
"""Create a AlphaTims object containing
all data in-memory (or memory mapping).
Attribute
---------
slice_as_dataframe
Attribute from AlphaTims.
If True, AlphaTims slicing returns a pd.DataFrame by default.
If False, AlphaTims slicing provides a np.int64[:] with raw indices.
The value can be modified on-the-fly.
"""

def __init__(self, msdata: MSData_Base, dda: bool, slice_as_dataframe: bool = True):
Expand All @@ -62,14 +70,15 @@ def __init__(self, msdata: MSData_Base, dda: bool, slice_as_dataframe: bool = Tr
slice_as_dataframe : bool
If True, slicing returns a pd.DataFrame by default.
If False, slicing provides a np.int64[:] with raw indices.
This value can also be modified after creation.
Default is True.
"""
self._use_calibrated_mz_values_as_default = False
self._import_alpharaw_object(msdata, dda)
self.thermo_raw_file_name = msdata.raw_file_path
self.bruker_d_folder_name = self.thermo_raw_file_name
self.slice_as_dataframe = slice_as_dataframe
self.slice_as_dataframe = (
slice_as_dataframe # This value can be modified after creation.
)
# Precompile
self[0, "raw"]

Expand Down

0 comments on commit 3e3cff0

Please sign in to comment.