search for: thuesen

Displaying 5 results from an estimated 5 matches for "thuesen".

2007 Oct 29
1
lm.boot function gives error
When I run this calculation library(ISwR) library(simple.boot) data(thuesen) fit <- lm(thuesen$short.velocity~thuesen$blood.glucose) summary(fit) fit.sb <- lm.boot(fit,R=1000,rows=F) summary(fit.sb) I get the following error from the lm.boot routine: newdata' had 100 rows but variable(s) found have 24 rows I don't know what this error means. Also...
2003 Sep 26
3
Std. errors of intercept and slope
Dear all, I have the following output generated by linear regression. Since there is only one regression intercept and one slope for one set of data, what is the meaning of std. error for intercept and that of slope? Thanks in advance. Sincerely, Minghua > data(thuesen) > attach(thuesen) > lm(short.velocity~blood.glucose) Call: lm(formula = short.velocity ~ blood.glucose) Coefficients: (Intercept) blood.glucose 1.09781 0.02196 > summary(lm(short.velocity~blood.glucose)) Call: lm(formula = short.velocity ~ blood.glucose) Residuals...
2007 Oct 19
2
In a SLR, Why Does the Hat Matrix Depend on the Weights?
...hat matrix is a function of the predictor variable alone. So, in the following example why do the values on the diagonal of the hat matrix change when I go from an unweighted fit to a weighted fit? Is the function hatvalues giving me something other than what I think it is? library(ISwR) data(thuesen) attach(thuesen) fit <- lm(short.velocity ~ blood.glucose) summary(fit) hatvalues(fit) W <- 1/blood.glucose fit.w <- lm(short.velocity ~ blood.glucose,weights=W) summary(fit.w) hatvalues(fit.w) Thanks for the help. Tom [[alternative HTML version deleted]]
2011 May 03
3
na.omit - Is it working properly?
I have a work around for this, but can someone explain why the first example does not work properly? I believed it worked in the previous version of R, by selecting just the rows=200525 and omitting the na's. I just upgraded to 2.13. I am also concern with the row numbers being different in the selections, should I be worried? FYI, I just selected the first few rows for demonstration, please
2006 May 02
4
Repeating tdt function on thousands of variables
...to run by each locus. >tdt(Genotype.914186, PGWide, famid, pid, fatid, motid, sex, affected ) Clearly I cannot type each locus in one at a time. Instead I want to loop it but am not sure how to do it. I tried lapply but it did not really work. The example in Dalgaard's book, >sapply( thuesen, mean, na. rm= T) seems to work with basic functions but not with something like tdt. So how does one tell R to calculate the tdt for each variable and output the result to a dataframe in which one of the columns is the locus ID.? Since I have another table in which every locus ID is in one col...