Skip to content

Commit

Permalink
Update modelplots.py
Browse files Browse the repository at this point in the history
  • Loading branch information
martinvonk committed Dec 27, 2022
1 parent 8575661 commit 3743419
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions pastas/model.py
Expand Up @@ -862,7 +862,7 @@ def _get_time_offset(self, freq: str) -> Type[Timedelta]:
else:
return Timedelta(0)

def _get_sim_index(self, tmin: Type[Timestamp], tmax: Type[Timestamp], freq: str, warmup: type[Timedelta], update_sim_index: Optional[Type[bool]] = False):
def _get_sim_index(self, tmin: Type[Timestamp], tmax: Type[Timestamp], freq: str, warmup: Type[Timedelta], update_sim_index: Optional[Type[bool]] = False):
"""Internal method to get the simulation index, including the warmup.
Parameters
Expand Down Expand Up @@ -1723,7 +1723,7 @@ def _check_response_tmax(self, cutoff: Optional[float] = None) -> Type[DataFrame

return check

def _check_parameters_bounds(self) -> Tuple[Type[Series], type[Series]]:
def _check_parameters_bounds(self) -> Tuple[Type[Series], Type[Series]]:
"""Internal method to check if the optimal parameters are close to pmin
or pmax.
Expand Down
4 changes: 2 additions & 2 deletions pastas/modelplots.py
Expand Up @@ -15,7 +15,7 @@
_table_formatter_params, _table_formatter_stderr

# Type Hinting
from pastas.typing import Type, Optional, List, pstAx, pstFi, pstTm, pstMl
from pastas.typing import Type, Optional, List, Union, pstAx, pstFi, pstTm, pstMl

logger = logging.getLogger(__name__)

Expand Down Expand Up @@ -853,7 +853,7 @@ def summary_pdf(self, tmin: Optional[pstTm] = None, tmax: Optional[pstTm] = None
return fig


def _get_height_ratios(ylims: List[list, tuple]) -> List[float]:
def _get_height_ratios(ylims: List[Union[list, tuple]]) -> List[float]:
height_ratios = []
for ylim in ylims:
hr = ylim[1] - ylim[0]
Expand Down

0 comments on commit 3743419

Please sign in to comment.