@@ -868,9 +868,7 @@ def _get_gross_column_widths(self) -> Sequence[int]:
868
868
body_column_widths = self ._get_body_column_widths ()
869
869
return [
870
870
max (* widths )
871
- for widths in zip (
872
- self .header_column_widths , body_column_widths
873
- )
871
+ for widths in zip (self .header_column_widths , body_column_widths )
874
872
]
875
873
876
874
def _get_body_column_widths (self ) -> Sequence [int ]:
@@ -901,9 +899,7 @@ def add_header_line(self) -> None:
901
899
header_line = self .SPACING .join (
902
900
[
903
901
_put_str (header , col_width )
904
- for header , col_width in zip (
905
- self .headers , self .gross_column_widths
906
- )
902
+ for header , col_width in zip (self .headers , self .gross_column_widths )
907
903
]
908
904
)
909
905
self ._lines .append (header_line )
@@ -912,9 +908,7 @@ def add_separator_line(self) -> None:
912
908
separator_line = self .SPACING .join (
913
909
[
914
910
_put_str ("-" * header_colwidth , gross_colwidth )
915
- for header_colwidth , gross_colwidth in zip (
916
- self .header_column_widths , self .gross_column_widths
917
- )
911
+ for header_colwidth , gross_colwidth in zip (self .header_column_widths , self .gross_column_widths )
918
912
]
919
913
)
920
914
self ._lines .append (separator_line )
@@ -924,9 +918,7 @@ def add_body_lines(self) -> None:
924
918
body_line = self .SPACING .join (
925
919
[
926
920
_put_str (col , gross_colwidth )
927
- for col , gross_colwidth in zip (
928
- row , self .gross_column_widths
929
- )
921
+ for col , gross_colwidth in zip (row , self .gross_column_widths )
930
922
]
931
923
)
932
924
self ._lines .append (body_line )
@@ -985,7 +977,7 @@ def _gen_rows_without_counts(self) -> Iterator[Sequence[str]]:
985
977
yield from zip (
986
978
self ._gen_line_numbers (),
987
979
self ._gen_columns (),
988
- self ._gen_dtypes (),
980
+ self ._gen_dtypes (),
989
981
)
990
982
991
983
def _gen_rows_with_counts (self ) -> Iterator [Sequence [str ]]:
@@ -994,7 +986,7 @@ def _gen_rows_with_counts(self) -> Iterator[Sequence[str]]:
994
986
self ._gen_line_numbers (),
995
987
self ._gen_columns (),
996
988
self ._gen_non_null_counts (),
997
- self ._gen_dtypes (),
989
+ self ._gen_dtypes (),
998
990
)
999
991
1000
992
def _gen_line_numbers (self ) -> Iterator [str ]:
@@ -1098,7 +1090,10 @@ def _gen_rows_without_counts(self) -> Iterator[Sequence[str]]:
1098
1090
1099
1091
def _gen_rows_with_counts (self ) -> Iterator [Sequence [str ]]:
1100
1092
"""Iterator with string representation of body data with counts."""
1101
- yield from zip (self ._gen_non_null_counts (), self ._gen_dtypes ())
1093
+ yield from zip (
1094
+ self ._gen_non_null_counts (),
1095
+ self ._gen_dtypes ()
1096
+ )
1102
1097
1103
1098
1104
1099
def _get_dataframe_dtype_counts (df : DataFrame ) -> Mapping [str , int ]:
0 commit comments