Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Hi dhowell,
Try the following macro: Sub AbsDiffs() Dim i As Long Dim j As Long Dim k As Long Dim l As Long k = 1 With ActiveSheet l = .Range("A65536").End(xlUp).Row For i = 1 To l - 1 For j = i + 1 To l .Cells(k, 3).Value = Abs(.Cells(i, 1).Value - .Cells(j, 1).Value) k = k + 1 Next Next End With End Sub It puts the absolute differences for values in column A into column C. Cheers -- macropod [MVP - Microsoft Word] wrote in message oups.com... | I have a column of unique numbers in ascending order: | | A | B | C | D | E | F | etc.... | | I would like Excel to create another column consisting of all the | absolute differences of those numbers: | | IE | | A-B | A-C | A-D | A-E | A-F | B-C | B-D | B-E | B-F | C-D | C-E | C-F | D-E | D-F | E-F | | I don't think this should be too hard, but I don't seem to be smart | enough to figure the syntax of the programming.... | |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Index Match Function Question | Excel Discussion (Misc queries) | |||
LINKEDRANGE function - a complement to the PULL function (for getting values from a closed workbook) | Excel Worksheet Functions | |||
numerical integration | Excel Discussion (Misc queries) | |||
clock | Excel Worksheet Functions | |||
Dynamic Function Reference Question | Excel Discussion (Misc queries) |