BookmarkSubscribeRSS Feed
TX_STAR
Obsidian | Level 7

Hello,

I am checking someone else's results, basic summary. We got the same N counts, same Means but different standard deviations. What could be the reason?

 

Thanks!

9 REPLIES 9
novinosrin
Tourmaline | Level 20

"We got the same "  do you mean are you comparing yours with his/her's

 

if yes, the datapoints seem to vary or spread differently between yours and someone else's

 

for eg:

 

data w;
 k=mean(4,4,4);
 std_k=std(4,4,4);
 k1=mean(2,4,6);
 std_k1=std(2,4,6);
 run;

 

TX_STAR
Obsidian | Level 7
we supposed to have used the same dataset. In any cases, that could result in same Ns, means but different standard deviations. But since we are checking independently, his/her dataset could have changed a little, such as slight updates for some values.
novinosrin
Tourmaline | Level 20

Sounds like you have answered your question 🙂

Reeza
Super User

@TX_STAR wrote:
we supposed to have used the same dataset. In any cases, that could result in same Ns, means but different standard deviations. But since we are checking independently, his/her dataset could have changed a little, such as slight updates for some values.

With N< 30 and the possibility of data having changed you're likely not actually using the same data. And thus the expectation of the same variance is not correct.

Reeza
Super User

@TX_STAR wrote:

Hello,

I am checking someone else's results, basic summary. We got the same N counts, same Means but different standard deviations. What could be the reason?

 

Thanks!


How different? Are you talking 6th decimal places or it's off by a lot?

TX_STAR
Obsidian | Level 7
first decimal. N <30
ballardw
Super User

Which procedure are you using?

 

Exact same data set or did you build a different set?

 

Maybe show the code you used and some output for your code and your coworker's output (if you don't have the code).

 

If the difference is very small it could be hardware differences such as different chipset. If running a different OS then that would be another potential for small differences. And another could just be setting formats or numbers of decimals for display.

r_behata
Barite | Level 11

Do a Proc Compare, it would be handy in zeroing down on the exact observations and the values that are varying between the two data sets. 

TX_STAR
Obsidian | Level 7

Hello

Thank you all for your help. I finally found out what caused the same mean but different standard deviation using the same data set. In proc mean I used the default, the other person used additional option VARDEF=n. So different SD formulas were applied when calculating the SD, SD for a sample (divided by n-1) and SD for population (divided by n).

 

Thanks!

sas-innovate-white.png

Register Today!

Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 9 replies
  • 1850 views
  • 2 likes
  • 5 in conversation