Also asking how to apply an ex range to a normal command.In a file of some 125k lines with a preamble followed by 8 columns of 10 character wide text, the contents of the column are 8 characters of numbers followed by spaces, except that the last column has no trailing space.If I wanted to wrap it such that each column becomes a row in order,I would set tw=9 (or 8 or 10?) and then use gq to wrap it.I hoped the easiest thing to do would be to go to the first line after the preamble and type something like:  :.,$gqAs you know, gq is not an ex mode command.I couldn't find in the help where the ex mode version of a formatting command is, I'd love both an answer to if that does exist what it is, or if it doesn't, and what you'd do to apply the gq normal mode command to everything to the end of the file. Is there something better than type:200000gq ?EG file:These are very nice data points from our experiment.This was carried out at our big data point lab by e@mail.tldIf you positioned your cursor on the fifth line, what would youtype in vim to turn all of these points into their own line?       1        10       100      1000     10000    100000   1000000  1000000010000001  10000010  10000100  10001000  10010000  10100000  11000000  20000000... 125k lines later88888881  18888818  18888188  18881888  18818888  18188888  11888888  28888888Where the desired format would be:These are very nice data points from our experiment.This was carried out at our big data point lab by e@mail.tldIf you positioned your cursor on the fifth line, what would youtype in vim to turn all of these points back into columns? [BONUS]1101001000100001000001000000100000001.25M lines of data points; Padding or alignment aren't important now.
Hard wrapping a range to textwidth with an ex command
cursor motions;ex mode;wrapping
I set tw=9 as you mentioned. Then I removed the spaces before de 1 in the first row and also left a blank line between the paragraph and the numbers.These are very nice data points from our experiment.This was carried out at our big data point lab by e@mail.tldIf you positioned your cursor on the fifth line, what would youtype in vim to turn all of these points into their own line?1        10       100      1000     10000    100000   1000000  1000000010000001  10000010  10000100  10001000  10010000  10100000  11000000  2000000088888881  18888818  18888188  18881888  18818888  18188888  11888888  28888888Then I put the cursor anywhere on the numbers and typed gqip. This is the result I obtained:These are very nice data points from our experiment.This was carried out at our big data point lab by e@mail.tldIf you positioned your cursor on the fifth line, what would youtype in vim to turn all of these points into their own line?11010010001000010000010000001000000010000001100000101000010010001000100100001010000011000000200000008888888118888818188881881888188818818888181888881188888828888888