Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -184,3 +184,4 @@ tests/data/day5.csv
# Other virtual environments
.venv-*
venv-*
notebooks/test.ipynb
2 changes: 2 additions & 0 deletions iglu_python/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,8 @@ def CGMS2DayByDay( # noqa: C901
if dt0 is None:
# Use most common time difference (for pandas 1.5.x backward compatibility)
time_diffs = pd.Series(data.index).diff().dropna()
if time_diffs.empty:
raise ValueError("Not enough data to calculate time step")
# Pandas TimedeltaIndex does not have a .mode() method directly.
# We'll convert to seconds and use pd.Series.mode()
# Use .dt accessor for pandas 1.5.x compatibility
Expand Down
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "hatchling.build"

[project]
name = "iglu_python"
version = "0.4.0"
version = "0.4.2"
description = "Python implementation of the iglu package for continuous glucose monitoring data analysis"
readme = "README.md"
requires-python = ">=3.11"
Expand All @@ -28,7 +28,7 @@ dependencies = [
"pandas",
"tzlocal",
"openpyxl",
"matplotlib",
"matplotlib"
]

[project.urls]
Expand Down
6 changes: 4 additions & 2 deletions uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading