@@ -129,7 +129,7 @@ function show(io::IO, ct::CoefTable)
129129    end 
130130
131131    sepsize =  3 
132-     hdots =  "   \u 2026   " 
132+     hdots =  "   …   " 
133133    mat =  [j ==  1  ?  NoQuote (rownms[i]) : 
134134           j- 1  ==  ct. pvalcol ?  NoQuote (sprint (show, PValue (cols[j- 1 ][i]))) : 
135135           j- 1  in  ct. teststatcol ?  TestStat (cols[j- 1 ][i]) : 
@@ -146,29 +146,31 @@ function show(io::IO, ct::CoefTable)
146146
147147    #  remove columns that do not fit on the screen
148148    maxcols =  length (A)
149-     totwidth =  sum (sum .(A)) +  2  *  (length (A) -  1 )+ sepsize
150149    if  maxcols <  nc+ 1 
151150        ncols =  min (nc, maxcols)
152151        mat =  mat[:, 1 : ncols]
152+         mat =  hcat (mat, [hdots for  i in  1 : nr])
153153        colnms =  colnms[1 : ncols]
154-         sepsize =  length (hdots)+ 1 
154+         sepsize =  textwidth (hdots)+ 1 
155155    else 
156156        sepsize =  0 
157157    end 
158158
159159    #  print table
160-     totwidth =  sum (sum .(A)) +  2  *  (length (A) -  1 )+ sepsize
160+     totwidth =  sum (sum, A) +  2  *  (maxcols -  1 ) +  sepsize
161+ 
161162    println (io, repeat (' ─'  , totwidth))
162163    print (io, repeat ('  '  , sum (A[1 ])))
163164    for  j in  1 : maxcols- 1 
164165        print (io, "   "  , lpad (colnms[j], sum (A[j+ 1 ])))
165166    end 
166167    maxcols <  nc+ 1  &&  print (io, lpad (hdots, sepsize))
167168    println (io, ' \n '  , repeat (' ─'  , totwidth))
168-     for  i in  1 : size (mat, 1 )
169-         Base. print_matrix_row (io, mat, A, i, 1 : size (mat, 2 ), "   "  )
170-         maxcols <  nc+ 1  &&  print (io, lpad (hdots, sepsize))
171-         i !=  size (mat, 1 ) &&  println (io)
169+     m, n = size (mat)
170+     for  i in  1 : m
171+         Base. print_matrix_row (io, mat, A, i, 1 : n, "   "  )
172+         maxcols <  nc+ 1  &&  (i+ 4 )% 5  ==  0  &&  print (io, lpad (hdots, sepsize))
173+         i !=  m &&  println (io)
172174    end 
173175    print (io, ' \n '  , repeat (' ─'  , totwidth))
174176    nothing 
0 commit comments