similar to: data analysis. R

Displaying 20 results from an estimated 10000 matches similar to: "data analysis. R"

2007 Dec 12
3
lm/model.matrix confusion (? bug)
Dear List-members, Hopefully someone will help through my confusion: In order to get the same coefficients as we get from the following ## require (MASS) summary ( lm(Gas ~ Insul/Temp - 1, data = whiteside) ) ...................... we need to do the following (if we use model.matrix to specify the model) ## summary ( lm(Gas ~ model.matrix(~ Insul/Temp - 1) - 1, data = whiteside) )
2008 Mar 05
1
testing for significantly different slopes
Hi, How would one go about determining if the slope terms from an analysis of covariance model are different from eachother? Based on the example from MASS: library(MASS) # parallel slope model l.para <- lm(Temp ~ Gas + Insul, data=whiteside) # multiple slope model l.mult <- lm(Temp ~ Insul/Gas -1, data=whiteside) # compare nested models: anova(l.para, l.mult) Analysis of Variance
2010 Feb 08
3
What is the equivalent function in R to xyplot in S?
Page 140 of MASS uses the function xyplot. But I don't find it in R. Is there a package that I should load to use xyplot. Or there is a function with a different name in R that does the same thing as xyplot in S. xyplot(Gas ~ Temp | Insul, whiteside, panel = function(x, y, ...) { panel.xyplot(x, y, ...) panel.lmline(x, y, ...) }, xlab = "Average external temperature (deg. C)", ylab
2007 Jul 28
1
Error when using the cat function
Is the following developed in my console output a recognized bug or am I using the cat function incorrectly? Thanks, Stan > ifelse(class(data[[n]])!="factor",{print("yes")},{print("no")}) [1] "yes" [1] "yes" > ifelse(class(data[[n]])!="factor",{cat("yes")},{cat("no")}) yesError in ans[test & !nas] <-
2008 Nov 21
1
question about shapiro.test()
Hi all! I tried to perform Shapiro-Wilk test for my sample of 243 values. > Us [1] -10.4 -13.1 -12.2 38.1 -18.8 -13.3 -11.7 29.3 49.7 6.8 12.7 16.3 [13] 5.8 -0.7 -29.4 4.1 38.8 -1.4 8.8 15.6 32.9 -5.3 19.1 35.8 [25] 4.0 -1.5 0.6 -4.2 -10.0 -4.0 1.1 48.9 -21.0 -5.3 5.8 -10.8 [37] 21.9 8.2 -3.2 -3.9 -2.3 12.6 -4.7 -8.0 11.8 27.4 -9.5 -20.8 [49]
2018 Dec 15
2
Documentation examples for lm and glm
A pragmatic solution could be to create a simple linear regression example with variables in the global environment and then another example with a data.frame. The latter might be somewhat more complex, e.g., with several regressors and/or mixed categorical and numeric covariates to illustrate how regression and analysis of (co-)variance can be combined. I like to use MASS's whiteside
2002 Jun 19
1
superscripts in xyplot labels
R-helpers; I tried to get a superscripted 3 in the following xyplot example but failed: >data(whiteside) >xyplot(Gas ~ Temp | Insul, whiteside, panel = function(x, y, ...) { panel.xyplot(x, y, ...) panel.lmline(x, y, ...) }, xlab = "Average external temperature (deg. C)", ylab = paste(paste("Gas consumption (1000", expression(ft^3),")"), aspect
2011 Jul 19
1
notation question
Dear list, I am currently writing up some of my R models in a more formal sense for a paper, and I am having trouble with the notation. Although this isn't really an 'R' question, it should help me to understand a bit better what I am actually doing when fitting my models! Using the analysis of co-variance example from MASS (fourth edition, p 142), what is the correct notation for the
2001 Jan 04
6
regression constraints?
gday R gurus, I have a multivariate regression for which I want to constrain the coefficients to be > 0. Is this possible? I've check the doco and searched CRAN but can't find anything. thanks, John Strumila -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send
2018 Dec 16
3
Documentation examples for lm and glm
On Sat, 15 Dec 2018, frederik at ofb.net wrote: > I agree with Steve and Achim that we should keep some examples with no > data frame. That's Objectively Simpler, whether or not it leads to > clutter in the wrong hands. As Steve points out, we have attach() > which is an excellent language feature - not to mention with(). Just for the record: Personally, I wouldn't recommend
2000 Sep 26
3
lm -- significance of x coefficient when I(x^2) is used
In "Modern Applied Statistics with S-Plus" 3rd ed., footnote on page 153 regarding a model lm(Gas~Insul/(Temp+I(Temp^2))-1,whiteside), I read "Notice that when the quadratic terms are present, first degree coefficients mean 'the slope of the curve at temperature zero', so a non-significant value does not mean that the linear term is not needed.
2008 Mar 06
2
Help with parsing a data file
Hi All, I need to parse data from a file, example shown below. The first two lines can be skipped, the third line contains the column names. The next 13 lines can be skipped. The next line "1991" is a year value, with the following 13 values data for that year. The file then repeats this format with (year, 13 lines of data for that year). I would ideally like to end up with an
2011 May 30
2
Basic question about three factor Anova
Read the data using scan(): # # a1 a2 a3 a4 # ------------- ------------- ------------- ------------- # b1 b2 b3 b1 b2 b3 b1 b2 b3 b1 b2 b3 # --- --- --- --- --- --- --- --- --- --- --- --- # # c1: # 4.1 4.6 3.7 4.9 5.2 4.7 5.0 6.1 5.5 3.9 4.4 3.7 # 4.3 4.9
2003 Jul 15
7
Excel can do what R can't?????
Hi there I thought this would be of particular interest to people using 'optim' functions and perhaps people involved with R development. I've been beaten down by R trying to get it to perform an optimization on a mass-balance model. I've written the same program in excel, and using the 'solver' function, it comes up with an answer for my variables (p, ACT, which
2010 Apr 25
1
Struggling with two questions : Newbie student .
Hi , I am struggling with these two question . Any help would be appreciated ,Im looking at doing them on r ? 1. Tests for indications of asbestos in the lungs of employees at an insulation manufacturer resulted in four persons with positive indications of asbestos being sent to a medical center for further testing . if 45% of the employees have positive indications of asbestos in their lungs ,
2010 Apr 19
1
What is mclust up to? Different clusters found if x and y interchanged
Hello All... I gave a task to my students that involved using mclust to look for clusters in some bivariate data of isotopes vs various mining locations. They discovered something I didn?t expect; the data (called tur) is appended below. p <- qplot(x = dD, y = dCu65, data = tur, color = mine) print(p) # simple bivariate plot of the data; looks fine mod1 <- Mclust(tur[,2:3]) mod1$G mod2
2016 Dec 17
19
llvm (the middle-end) is getting slower, December edition
First of all, sorry for the long mail. Inspired by the excellent analysis Rui did for lld, I decided to do the same for llvm. I'm personally very interested in build-time for LTO configuration, with particular attention to the time spent in the optimizer. Rafael did something similar back in March, so this can be considered as an update. This tries to include a more accurate high-level
2003 Jun 07
1
Extracting Numbers from MANOVA output
Hi, Suppose I have: > summary(manova(plank.man)) Df Pillai approx F num Df den Df Pr(>F) plankton.new[, 1] 1 0.5267 9.8316 6 53 2.849e-07 *** Residuals 58 --- Signif. codes: 0 `***' 0.001 `**' 0.01 `*' 0.05 `.' 0.1 ` ' 1 My understanding is the MANOVA summary returns a list.
2006 Mar 30
2
Unbalanced Manova
Dear all, I need to do a Manova but I have an unbalanced design. I have morphological measurements similar to the iris dataset, but I don't have the same number of measurements for all species. Does anyone know a procedure to do Manova with this kind of input in R? Thank you very much, Naiara. -------------------------------------------- Naiara S. Pinto Ecology, Evolution and Behavior 1
2003 Nov 20
4
p value in MANOVA
Dear R users, Can anyone tell me how to get the p value out of the output from summary.manova? I tried all the methods I can think of, but failed. Many thanks Yu-Kang _________________________________________________________________ ¥ß§Y¥Ó½Ð MSN Mobile ªA°È¡G¦b±zªº¤â¾÷¤W¦¬µo MSN Hotmail http://msn.com.tw/msnmobile