View Single Post
  #2   Report Post  
Zack Barresse
 
Posts: n/a
Default

Hello,

Maybe something like this ...

Sub HighlightForMePlease()
Dim rngLook As Range, c As Range, firstAddy As String
Dim lngSTDEV1 As Double, lngSTDEV2 As Double
Set rngLook = Sheets("test").Range("A2:F15") '<<== CHANGE THIS TO SUIT
With Application.WorksheetFunction
lngSTDEV1 = .Average(rngLook) + .StDev(rngLook)
lngSTDEV2 = 2 * .StDev(rngLook)
End With
For Each c In rngLook
If IsNumeric(c) Then
If c.Value < lngSTDEV1 And c.Value lngSTDEV2 Then
c.Interior.ColorIndex = 3
End If
End If
Next
End Sub


--
Regards,
Zack Barresse, aka firefytr

"learner" wrote in message
...
I am new to excel, my question may be silly for you. But I really don't
know
how to do it and hope to get your help.

I need to do statistic analysis of my data table which has lots of
columns.
First of all, in each column, I want to find and highlight the value that
is
bigger than mean+two times standard derivation, or smaller than mean-2*
standard derivation. Do you have any suggestions about how to do it?

Thanks alot,

ming