I have a list that looks like
1.530 2.895
4.362 50.14
3.14 2.7
And I want it to look like
1.530
2.895
4.362
50.14
3.14
2.7
I suspect there is a clever way to use a rectangle to do this but I cannot figure it out.
You don't need a rectangle for this job.
Just use (query-replace-regexp "[ ]+" "\n")
to replace the separating spaces by linebreaks.
The corresponding key-sequence is:
C-M-% [ ]+
RET C-q C-j RET
Meaning:
query-replace-regexp
[ ]+
the regular expression for the strings to be replaced (one or more spaces)quoted-insert
)+
.
Commented
Nov 22, 2016 at 18:56
C-M-% [ <SPACE> ] + <RET> C-j <RET>
... The key sequence for(query-replace-regexp "[ ]+" "\n")
C-j
because it simply removed the spaceC-q C-j
instead of onlyC-j
.C-q
causes literal insertion of the next keystroke.