If I have a grid of values that doesn't divide evenly, for example a list of 17 values, and split it into a 7x3 grid, then draw frames around each element:
Grid[Partition[Range@17, UpTo@7], Frame -> All]
This creates grid lines around the 4 empty elements in the last row:
How do I get
Grid to not frame those empty elements? I'd still want the bottom borders around 11-14 and the right border on 17, if that makes sense.
I can sort of do it with it
TableForm[Partition[Framed[#, ImageSize -> 40] & /@ Range@17, UpTo@7], TableSpacing -> 0]
...but the frame lines look a little bit weird. There's gaps at the top of each vertical line, and they're twice as thick as the horizontal lines (probably because there's the left and right sides of each being pushed together).
Grid's lines are much cleaner; is there a way to do it? Thanks!