Reverse a "row" of numbers (flip flop them)?

G

Guest

I have 50 rows of numbers, with the last number being last number in the
sequence. I want to reverse these numbers, so the most recent number is the
first number. How do I do this? Been up all night trying to figure this
out. Thanks for you help, I just have to get some sleeeeeeeeeeeeeeep!
 
G

Guest

Lets say in A1 thru J1 we have:
1 2 3 4 5 6 7 8 9 10

In a helper row enter:
=INDEX($A1:$J1,11-COLUMN()) and copy across to see:
10 9 8 7 6 5 4 3 2 1

Finally copy the helper row and paste/special/value back into row 1.
 
M

MartinW

Hi wannabe,

In row 51(helper row) put 1 in the first cell and drag across as far as
needed, hold down ctrl and let go the left button then let go ctrl.

Then select all of your data including your helper row
and go to Data>Sort then click on the options button
and select Sort left to right then click OK
then select row 51, descending and OK

HTH
Martin
 
G

Guest

Gary
So sorry, I'm just not getting it. I have a PHD in business, but not Excel.
What is the "helper row"? The row that ends in "fx"? Then I enter
=INDEX($A1:$J1,11-COLUMN())
Then what?
Do I hit enter or?????
 
G

Guest

MartinW
I think I almost had it, at least I had it once.
Step 1: In helper row, put 1 in the first cell and drag (with ctrl or shift
?) held down.
Step 2: Select ? (highlight ? with control or shift held down?????)
I am so close.
 
M

MartinW

OK your last post doesn't make a lot of sense to me.
Let's start again.

What cell range is your data in, (i.e. A1:K50 or whatever)
Do you want to flip this data horizontally or vertically?

Waiting your reply
Martin
 
R

Ragdyer

If your numbers are *already* in numerical order, with the largest at the
bottom, and the smallest at the top, you can simply sort that column
*descending*.

To sort:
Select all the cells in the column containing your numbers, then,
<Data> <Sort>
Click on "Descending", then <OK>.

If your numbers are *not* in numerical order, and you wish to just reverse
the order that they are presently in, you can do what the other responders
suggested.

Since you sound confused, I'll just elaborate on their instructions here:

With your numbers in a column, in *no particular* order, you will add a
"helper" column, containing a list of numbers that *are* in numerical order.
This allows you to then sort both columns, using the helper column as the
sort key.
By selecting *both* columns, prior to starting the sort, the column
designated as the sort key (helper column) will sort in the manner you chose
(ascending or descending), and take the original column along with it.

So, make sure the helper column is adjacent to the original, and fill it
with a set of numbers in order.
Say your original data is in A1 to A50.
In B1 enter a 1,
And in B2 enter a 2.

Now, select *both* cells, and drag down the fill handle to B50.
This automatically fills the cells with consecutive numbers.

Select *both* columns, A1 to B50,
Click on <Data> <Sort>,
Make sure that the "Sort By" window displays "Column B".
Click on "descending", then <OK>.

You'll see that Column B now has 50 at the top and 1 at the bottom, and that
your original data column followed along and "flipped", the same as the
helper column.

You can now delete that helper column ( B ) if you wish.
 
G

Guest

Sorry MartinW
I have 85 rows of numbers with 49 columns. The numbers have been entered in
each row, first to last. I am trying to reverse those numbers from last to
first, reading left to right in each row. I want to do this for all columns.
Does this make sense?
 
M

MartinW

OK
Put 1 in cell A86 click on the fill handle(bottom right corner of cell) and
drag
across to AW86 hold down control, then let go the left button.
That should leave you with 1 to 49 in that row.

Now highlight all of your data including your helper row (A1 to AW86)
Go to Data>Sort then click on the options button
and select Sort left to right then click OK
In the pulldown menu select row 86, check descending and OK

That should do it.
Marrtin
 
G

Guest

Yes it does, now.

Let me try to help. The suggestions so far have all been good, I just think
maybe a little more detail is needed, and I'm going to veer a little from the
paths previously taken, so...

To make sure we don't screw things up, make a copy of the sheet to practice
on. (Right-click on sheet's name tab, choose Move or Copy, and check the
Make Copy option).

Your helper row is going to be row 86, the row below the last row of numbers
you need to re-arrange. Type a 1 in cell A86, press [Enter]. Click back in
cell A86 again. Now, up above the column inidicators you should see a white
box with A86 in it. Click in that box and type A86:AW86 and press [Enter].
All cells from A86 to AW86 should be highlighted now. Note: Adjust A and AW
to refer to the first / last columns you have numbers to be reversed in -
keep column references consistent during later steps here also.

Go to the menu bar and select Edit then select Fill and finally select
Series...
The Series dialog box will appear and just make sure that
Series in Rows is checked,
Linear is checked as the fill type
and that 1 is the Step Value
Click [OK]
Now Row 86 should have series 1 through 49 in individual cells.

Click in cell AW86 and hold down the left mousebutton while dragging left
and up to the first row and first column where you have numbers to be sorted
(A1).

Now, in the menu bar, choose Data and then choose Sort. When the dialog box
opens, choose [Options...] and make sure that Sort Left to Right is selected.
Click [OK] and then in the top entry area on the sort dialog, pick Row 86 as
the row to sort by, and choose DESCENDING as the sort order. Click OK.

All of the columns data should be reversed at this point. Click any cell to
unselect the whole bunch.
 
J

joeu2004

Sorry MartinW
I have 85 rows of numbers with 49 columns. The numbers have been entered in
each row, first to last. I am trying to reverse those numbers from last to
first, reading left to right in each row. I want to do this for all columns.

What MartinW was suggesting is: you put the numbers 1, 2, 3, etc
through 49 into cells in a helper row in row 86.

You could type those manually. Alternatively, put the numbers 1 and 2
into adjacent cells. Select the two cells and drag to the right by
doing ctrl-left-click on the handle (small box) in the lower-right
corner of the two-cell outline.

Once the helper row is set up, it is a simple matter to sort that row
in descending order; that is, 49, 48, etc through 1. By selecting all
86 rows and doing the sort descending sort on row 86, that will
reverse the order of the first 85 rows simultaneiously.

To do this.... First, select all 49 columns of all 86 rows. Then
click on Data >> Sort on the toolbar, click Options and click the
radio button next Sort Left To Right under Orientation, and click OK.
Select Row 86 from the drop-down menu under Sort By, click the radio
button next to Descending, and click OK.

Voila! The 85 rows should not be in reverse order. You can delete
row 86 by clicking on the row number on the far left, then right-click
and click on Delete.

PS: The helper row is not needed if you one of the 85 rows already
contains sequential values; for example, dates. Then you can simply
select that row from the drop-down menu under Sort By.

HTH.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top