Need help calculating St Deviation of Dynamic List

GetHitFooL

New Member
Joined
May 19, 2015
Messages
13
Good Afternoon Guys!

So here is my problem. I have a list of names on sheet 1, roughly 60 different people. Then on sheet two that contains all my data, I have 2000 rows which includes everyones numbers. In column D of sheet 2 I have the names and in column K I have the value.

I know that I could do =stdev() function and just go through the entire list on sheet3 to capture all the values but I want this to be a living document that is able to refresh using my macro.

I currently already have a macro that runs through all the data and then calculates the average so I have the loop.

For Example, lets say sheet 1 has the following info:

Column A
Name
Jimmy
John
Bob
Chris

Column B
St Deviation


On sheet 2
Name
Jimmy
Jimmy
Chris
Bob
John
Bob
Jimmy

Value
8
6
7
3
1
9
7


So for this macro I want it to loop through and compute the st dev of each. Jimmy for example would get the formula =stdev(8,6,7)
 

Excel Facts

Round to nearest half hour?
Use =MROUND(A2,"0:30") to round to nearest half hour. Use =CEILING(A2,"0:30") to round to next half hour.
Use a macro if you like to generate the unique name list, but all you need for the standard deviation is an Excel formula.

E2: {=IFERROR(STDEV.S(IF(A$2:A$8=D2,B$2:B$8)),"-")} Array-entered

You could use Excel or VBA to make the range dynamic.

ABCDE
Name
JimmyJimmy
JimmyChris
ChrisBob
Bob
John
Bob
Jimmy

<colgroup><col style="width: 25pxpx"><col><col><col><col><col></colgroup><thead>
</thead><tbody>
[TD="align: center"]1[/TD]

[TD="align: right"]Value[/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: center"]STDEV[/TD]

[TD="align: center"]2[/TD]

[TD="align: right"]8[/TD]
[TD="align: right"][/TD]

[TD="align: center"]1.00[/TD]

[TD="align: center"]3[/TD]

[TD="align: right"]6[/TD]
[TD="align: right"][/TD]

[TD="align: center"]-[/TD]

[TD="align: center"]4[/TD]

[TD="align: right"]7[/TD]
[TD="align: right"][/TD]

[TD="align: center"]4.24[/TD]

[TD="align: center"]5[/TD]

[TD="align: right"]3[/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]

[TD="align: center"]6[/TD]

[TD="align: right"]1[/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]

[TD="align: center"]7[/TD]

[TD="align: right"]9[/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]

[TD="align: center"]8[/TD]

[TD="align: right"]7[/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]
[TD="align: right"][/TD]

</tbody>

 
Upvote 0

Forum statistics

Threads
1,223,231
Messages
6,170,884
Members
452,364
Latest member
springate

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top