Skip to content

Commit 4a531a9

Browse files
committed
fix: fix type annotation
1 parent 96385cb commit 4a531a9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

gen_surv/integration.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
SKSURV_AVAILABLE = False
1111

1212

13-
def to_sksurv(df, time_col="time", event_col="status"):
13+
def to_sksurv(df: pd.DataFrame, time_col="time", event_col="status"):
1414
"""
1515
Convert a pandas DataFrame to a scikit-survival structured array.
1616
@@ -51,7 +51,7 @@ def to_sksurv(df, time_col="time", event_col="status"):
5151
return Surv.from_dataframe(event_col, time_col, df)
5252

5353

54-
def from_sksurv(y, time_col="time", event_col="status"):
54+
def from_sksurv(y: np.ndarray, time_col="time", event_col="status"):
5555
"""
5656
Convert a scikit-survival structured array to a pandas DataFrame.
5757

0 commit comments

Comments
 (0)