File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -33,5 +33,5 @@ keywords:
3333 - spectroscopy
3434 - submillimeter
3535license : MIT
36- version : 2025.6.1
37- date-released : ' 2025-06-23 '
36+ version : 2025.8.0
37+ date-released : ' 2025-08-18 '
Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ DESHIMA code for data analysis
1111## Installation
1212
1313``` shell
14- pip install decode==2025.6.1
14+ pip install decode==2025.8.0
1515```
1616
1717## Quick look
Original file line number Diff line number Diff line change 1111 "stats" ,
1212 "utils" ,
1313]
14- __version__ = "2025.6.1 "
14+ __version__ = "2025.8.0 "
1515
1616
1717# submodules
Original file line number Diff line number Diff line change @@ -46,6 +46,7 @@ def phaseof(
4646 * ,
4747 keep_attrs : bool = False ,
4848 keep_coords : bool = False ,
49+ keep_name : bool = False ,
4950) -> xr .DataArray :
5051 """Assign a phase to each value in a 1D DataArray.
5152
@@ -57,6 +58,7 @@ def phaseof(
5758 da: Input 1D DataArray.
5859 keep_attrs: Whether to keep attributes of the input.
5960 keep_coords: Whether to keep coordinates of the input.
61+ keep_name: Whether to keep name of the input.
6062
6163 Returns:
6264 1D int64 DataArray of phases.
@@ -69,4 +71,11 @@ def phaseof(
6971 is_transision .data [1 :] = da .data [1 :] != da .data [:- 1 ]
7072
7173 phase = is_transision .cumsum (keep_attrs = keep_attrs )
72- return phase if keep_coords else phase .reset_coords (drop = True )
74+
75+ if not keep_coords :
76+ phase = phase .reset_coords (drop = True )
77+
78+ if not keep_name :
79+ phase = phase .rename (None )
80+
81+ return phase
Original file line number Diff line number Diff line change 11[project ]
22name = " decode"
3- version = " 2025.6.1 "
3+ version = " 2025.8.0 "
44description = " DESHIMA code for data analysis"
55readme = " README.md"
66keywords = [
You can’t perform that action at this time.
0 commit comments