Re: [R] Interactions in regression

2024-03-01 Thread Jacek Kownacki
Hi Rolf, No it is not. I don't know to which question did you want to respond ? I desribed everything in my first email and attached links from SO with pictures included, which are quite understandable. Cheers, Jacek śr., 28 lut 2024 o 19:42 Jacek Kownacki napisał(a): > Hi Rolf, > No it is no

Re: [R] Interactions in regression

2024-03-01 Thread Jacek Kownacki
Hi Rolf, No it is not. I don't know to which question did you want to respond ? I desribed everything in my first email and attached links from SO with pictures included, which are quite understandable. Cheers, Jacek wt., 27 lut 2024 o 02:29 Rolf Turner napisał(a): > > I have no real idea what

Re: [R] Interactions in regression

2024-02-26 Thread Rolf Turner
I have no real idea what you are trying to do, but if a table is what you want, you can probably get it using the table() function. Or, more likely, the xtabs() function. Using your example from an earlier post (adjusted to make it comprehensible to the human mind): set.seed(1000) time <-

Re: [R] Interactions in regression

2024-02-26 Thread Jacek Kownacki
Hi, I do not want to make a plot, I try to make an output table in R, (in GUI like Stata this is trivially easy task) with regard to SO OP question. As I mentioned, in paper I would not do this, but out of curiosity I use R this time trying to create it. If in R this is trivial task as well, could

Re: [R] Interactions in regression

2024-02-25 Thread Bert Gunter
It is trivial in R to add whatever decorations to a plot that you would like, but that requires that you go beyond point and click production of graphics and write actual code. If you are unwilling or unable to do this, you are stuck with whatever various packaged graphics functionality provides.So

[R] Interactions in regression

2024-02-25 Thread Jacek Kownacki
Hi All, I stumbled upon some topics regarding interactions in anova and regression and packages for tabulating and visualizations the results of them. Here we are: https://stackoverflow.com/questions/77933272/how-to-add-a-reference-level-for-interaction-in-gtsummary-and-sjplot/77935742#77935742 , h

Re: [R] interactions in GAMs

2012-11-27 Thread Simon Wood
David, I think that the colorsex approach is the right one, and colorsex should initially be included as a main effect, because the smooths are centred for factor by variables (see e.g. ?gam.models). Whether you then choose to drop this main effect, as it appears to be non-significant, is a m

[R] interactions in GAMs

2012-11-27 Thread chirleu
Hi all, I wonder if it's possible to include a double interaction in a GAM formula. Example: If I do this: mod=gam(energy~s(size, *by=color, by=sex*, k=5) + temperature, ...) I get the interaction betwen size*color and size*sex. But I need size*color*sex, being size a smoother. I've created a n

Re: [R] Interactions in a nls model

2011-02-09 Thread Anthony Lawrence Nguy-Robertson
Gabor, Looking at your 2nd response, your suggestion is similar to that of Derek Ogle. It was my misinterpretation from your first response that elicited my original rebuttal. I apologize. Thanks, Tony On 2/9/2011 2:47 PM, Gabor Grothendieck wrote: On Wed, Feb 9, 2011 at 1:02 PM, Anthony La

Re: [R] Interactions in a nls model

2011-02-09 Thread Gabor Grothendieck
On Wed, Feb 9, 2011 at 1:02 PM, Anthony Lawrence Nguy-Robertson wrote: > Thank you R-forum for you generous help. > > Gabor Grothendieck, I am not sure if anova in the form that you suggested is > the most appropriate (This is probably more of a statistics related, rather > than R related at this

Re: [R] Interactions in a nls model

2011-02-09 Thread Anthony Lawrence Nguy-Robertson
help@r-project.org Subject: Re: [R] Interactions in a nls model On Tue, Feb 8, 2011 at 4:12 PM, Anthony Lawrence Nguy-Robertson wrote: I am interested in testing two similar nls models to determine if the lines are statistically different when fitted with two different data

Re: [R] Interactions in a nls model

2011-02-08 Thread Gabor Grothendieck
On Tue, Feb 8, 2011 at 11:43 PM, Gabor Grothendieck wrote: > On Tue, Feb 8, 2011 at 4:12 PM, Anthony Lawrence Nguy-Robertson > wrote: >> I am interested in testing two similar nls models to determine if the lines >> are statistically different when fitted with two different data sets; one >> corn

Re: [R] Interactions in a nls model

2011-02-08 Thread Gabor Grothendieck
On Tue, Feb 8, 2011 at 4:12 PM, Anthony Lawrence Nguy-Robertson wrote: > I am interested in testing two similar nls models to determine if the lines > are statistically different when fitted with two different data sets; one > corn, another soybean. I know I can do this in linear models by testing

Re: [R] Interactions in a nls model

2011-02-08 Thread Anthony Lawrence Nguy-Robertson
Bert, Thanks for the input. I was hoping for an easy answer, but as life is, there usually isn't one. I will find a statistician here on campus that might be able to help. Just so you know, the data is remote sensing data that is an average of 9 measurements on one day. However, the data set

Re: [R] Interactions in a nls model

2011-02-08 Thread Bert Gunter
Nonlinear models are an entirely different kettle of fish then linear models. You need to specify exactly how the different crops affect the parameters in your growth model. I suggest you consult a local statistician for help (this is not an R question). Incidentally, depending on the nature of yo

[R] Interactions in a nls model

2011-02-08 Thread Anthony Lawrence Nguy-Robertson
I am interested in testing two similar nls models to determine if the lines are statistically different when fitted with two different data sets; one corn, another soybean. I know I can do this in linear models by testing for interactions. See Introductory Statistics with R by Dallgaard p212-21

[R] Interactions in GAM

2010-09-08 Thread Lucia Cañas
Thank you so much for your answer, it has been really useful. I have already included the interactions in the models and I have obtained better results. Best regards, Lucía Cañás Lucía Cañás Ferreiro Instituto Español de Oceanografía Centro Oceanográfico de A Coruña Paseo Marítimo Alcalde Fr

Re: [R] Interactions in GAM

2010-09-03 Thread Simon Wood
> My main doubts are: > 1.Is the use of "by" and "te" right with the negative binomial > distribution and with the binomial distribution? -- yes! These things specify the `linear predictor' of the model --- the correctness of the linear predictor does not usually depend on the response di

[R] Interactions in GAM

2010-09-03 Thread Lucia Cañas
Hello R users, I am working with the GAM to inspect the effect of some factors (year, area) and continuous variables (length, depth, latitude and longitude) on the intensity and prevalence of the common parasite Anisakis. I would like introduce interaction in my models, both "continuous variabl

[R] interactions in repeated measures ANOVA

2010-08-12 Thread Nicola Spotorno
Hello all, I apply Repeated measures ANOVA for analyzing ERPs data. To do this I use lme() function and glht() for the post hoc analysis. I followed the very useful suggestions found in this help list but I have a problem. I do not know how to test the interaction between different levels of

Re: [R] Interactions in GAMMs

2010-07-21 Thread Gavin Simpson
On Wed, 2010-07-21 at 16:17 +0100, Karen Moore wrote: > Hi, > > I've an issue adding an interaction to a GAMM: > > My model was of form: > > gamm1 <- gamm(TOTSR ~ fROT + s(PH) + s(LOI) + s(ASP) + s(SQRT_ELEV) + CANCOV > + s(SQRT_TOTCWD) + s(WELLF) + s(WELLN) + s(OLDWDLD) + s(DISTWOOD) + > s(Annp

Re: [R] Interactions in GAMMs

2010-07-21 Thread David Winsemius
On Jul 21, 2010, at 11:17 AM, Karen Moore wrote: Hi, I've an issue adding an interaction to a GAMM: My model was of form: # Package? Probably: require(mgcv) gamm1 <- gamm(TOTSR ~ fROT + s(PH) + s(LOI) + s(ASP) + s(SQRT_ELEV) + CANCOV + s(SQRT_TOTCWD) + s(WELLF) + s(WELLN) + s(OLDWDLD)

Re: [R] Interactions in GAMMs

2010-07-21 Thread Vito Muggeo (UniPa)
Hi Karen, I think you should decide what you mean for "interaction". s(x:y) is meaningless If you want to fit a surface you should use s(x,y). If you want to fit a varying coefficient model (interaction between a linear and a smooth term) you should use the argument by in s(). The help file

[R] Interactions in GAMMs

2010-07-21 Thread Karen Moore
Hi, I've an issue adding an interaction to a GAMM: My model was of form: gamm1 <- gamm(TOTSR ~ fROT + s(PH) + s(LOI) + s(ASP) + s(SQRT_ELEV) + CANCOV + s(SQRT_TOTCWD) + s(WELLF) + s(WELLN) + s(OLDWDLD) + s(DISTWOOD) + s(Annprec) + s(OLDWDLD:DISTWOOD) + (1|fSITE), family = poisson, data = BIOFOR

[R] Interactions

2010-02-12 Thread Jaclyn Maghapon
Hi R community, I am trying to fit a PLS model with response Y and predictor X, where X consists of at least 30 columns (say x1, x2, ..., x30).  Aside from studying the relationship of Y and x1, ..., x30, I am also interested in studying the effect of quadratic terms (x1^2, ..., x30^2) and two-

[R] Interactions in 'MatchBalance' of the package 'Matching'

2009-11-23 Thread anna0102
Hello together, In the package 'Matching' there ist a possibility to determine balance statistics after Matching with the function 'MatchBalance'. In this function there has a formula 'formul' to be given. I'm wondering how I can implement all two-way interactions, without specifying them explicit

Re: [R] "interactions" feature in RF?

2009-10-22 Thread Liaw, Andy
That has not yet been implemented in the R version of the package. Best, Andy > -Original Message- > From: r-help-boun...@r-project.org > [mailto:r-help-boun...@r-project.org] On Behalf Of Chrysanthi A. > Sent: Thursday, October 22, 2009 6:40 AM > To: r-help@r-project.or

[R] "interactions" feature in RF?

2009-10-22 Thread Chrysanthi A.
Hi all, Is there a possibility of getting the "interactions" feature values for the variables of a dataset by applying the Random Forest algorithm? Thanks, Chrysanthi [[alternative HTML version deleted]] __ R-help@r-project.org mailing list h

Re: [R] interactions and stall or memory shortage

2009-09-01 Thread Ben Bolker
The short answer is that you're trying to make a categorical interaction out of continuous variables, so that the resulting factors i2 and i3 have 1050 and 7200 levels respectively. (Note to people trying to reproduce this example: you'll need library(emdbook); library(bbmle); data(Lily_sum) .

Re: [R] interactions and stall or memory shortage

2009-08-31 Thread jim holtman
Use "Rprof" on a small sample and determine where the time is being spent. Do some periodic gc() or memory.size() to see how fast you are using up memory. Do an object.size on all your objects to see see how be they are. This would help in the determination of the problem. On Mon, Aug 31, 2009

[R] interactions and stall or memory shortage

2009-08-31 Thread alexander russell
Hello, After putting together interaction code that worked for a single pair of interactions, when I try to evaluate two pairs of interactions( flowers*gopher, flowers*rockiness) my computer runs out of memory, and the larger desktop I use just doesn't go anywhere after about 20 minutes. Is it re