Give this a try,
Option Explicit
Sub abc()
Dim r As Long, lr As Long, c As Long, lc As Long
Dim a, i As Long, ii As Long
With Worksheets("sheet1")
lr = .Cells(Rows.Count, "a").End(xlUp).Row
lc = .Cells(1, Columns.Count).End(xlToLeft).Column
ReDim a(1 To lr, 1 To lc / 2 + 1)
i = 1
For c = 1 To lc
If Len(Trim$(.Cells(10, c))) > 0 Then
ii = ii + 1
a(i, ii) = .Cells(10, c)
End If
Next
For r = 11 To lr Step 18
i = i + 1
a(i, 1) = .Cells(r, 1)
ii = 2
For c = 2 To lc Step 2
a(i, ii) = WorksheetFunction.Average(.Range(.Cells(r, c).Address, .Cells(r + 17, c).Address))
ii = ii + 1
Next
Next
End With
With Worksheets.Add
With .Cells(1).Resize(i, UBound(a, 2))
.NumberFormat = "0.00000000"
.Value = a
End With
.Cells.EntireColumn.AutoFit
End With
End Sub
Bookmarks