File tree Expand file tree Collapse file tree 1 file changed +7
-6
lines changed Expand file tree Collapse file tree 1 file changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -99,18 +99,19 @@ def to_dict(self, json=False):
99
99
def ci_low (self ):
100
100
"""Return the lower bracket of the confidence intervals."""
101
101
if self .confidence_intervals :
102
- try :
102
+ if isinstance ( self . confidence_intervals [ 0 ], pd . Series ) :
103
103
return self .confidence_intervals [0 ][0 ]
104
- except IndexError :
104
+ else :
105
105
return self .confidence_intervals [0 ]
106
106
return None
107
107
108
108
def ci_high (self ):
109
109
"""Return the higher bracket of the confidence intervals."""
110
- try :
111
- return self .confidence_intervals [1 ][0 ]
112
- except IndexError :
113
- return self .confidence_intervals [1 ]
110
+ if self .confidence_intervals :
111
+ if isinstance (self .confidence_intervals [1 ], pd .Series ):
112
+ return self .confidence_intervals [1 ][0 ]
113
+ else :
114
+ return self .confidence_intervals [1 ]
114
115
return None
115
116
116
117
def ci_valid (self ) -> bool :
You can’t perform that action at this time.
0 commit comments