[R] weight in lm

Troels Ring tring at gvdnet.dk
Mon Aug 14 10:13:58 CEST 2017


Dear friends - I hope you will accept a naive question on lm: R version 
3.4.1, Windows 10

I have 204 "baskets" of three types corresponding to factor F, each of 
size from 2 to 33 containing measurements, and need to know if the 
standard deviation on the measurements  in each basket,sdd, is different 
across types, F. Plotting the observed sdd  versus the sizes from 2 to 
33, called "k" , does show a decreasing spread as k increases towards 33.

I tried lm(sdd ~ F,weight=k) and got different results if omitting the 
weight argument but would it be the correct way to use sqrt(k) as weight 
instead?

Best wishes

Troels Ring
Aalborg, Denmark



More information about the R-help mailing list