ve been much more "understandable".
>
>
> Thanks for your time...and all the quick replies
>
>
> -Original Message-
> From: Rui Barradas [mailto:ruipbarra...@sapo.pt]
> Sent: 28 September 2012 16:49
> To: Krunal Nanavati
> Cc: David Winsemius;
48628
>> 445351
>>
>>
>>
>>
>> When I enter " lm.list2[[2]]$coefficient[2] " it gives me the below
>> output
>>
>> Price2
>> -5759030
>>
>> And when I enter " lm.list2[[2]]$coefficient[[2]] " ...I
Regards,
Krunal Nanavati
9769-919198
-Original Message-
From: Rui Barradas [mailto:ruipbarra...@sapo.pt]
Sent: 28 September 2012 16:02
To: Krunal Nanavati
Cc: David Winsemius; r-help@r-project.org
Subject: Re: [R] Running different Regressions using for loops
Hello,
Try
names(lm.
t; Price2 "is there a
statement for that??
Thanks & Regards,
Krunal Nanavati
9769-919198
-Original Message-
From: Rui Barradas [mailto:ruipbarra...@sapo.pt]
Sent: 28 September 2012 15:18
To: Krunal Nanavati
Cc: David Winsemius; r-help@r-project.org
Subject: Re: [R] Running
2) }
Thanks & Regards,
Krunal Nanavati
9769-919198
-Original Message-
From: Rui Barradas [mailto:ruipbarra...@sapo.pt]
Sent: 28 September 2012 16:02
To: Krunal Nanavati
Cc: David Winsemius; r-help@r-project.org
Subject: Re: [R] Running different Regressions using for loops
Hello,
Try
pt]
Sent: 28 September 2012 15:18
To: Krunal Nanavati
Cc: David Winsemius; r-help@r-project.org
Subject: Re: [R] Running different Regressions using for loops
Hello,
To access list elements you need `[[`, like this:
summ.list[[2]]$coefficients
Or Use the extractor function,
coef(summ.list[[2]])
Rui B
arra...@sapo.pt]
Sent: 27 September 2012 21:55
To: Krunal Nanavati
Cc: David Winsemius; r-help@r-project.org
Subject: Re: [R] Running different Regressions using for loops
Hello,
Inline.
Em 27-09-2012 13:52, Krunal Nanavati escreveu:
Hi,
Thanks for all your help. I am stuck again, but with a new pr
Hello, Krunal,
try
summ.list[[2]]$coefficients[2]
Note the double square brackets (as summ.list is a list)!
Hth,
Gerrit
On Fri, 28 Sep 2012, Krunal Nanavati wrote:
Hi Rui,
Excellent!! This is what I was looking for. Thanks for the help.
So, now I have stored the result of the 10 regr
s & Regards,
Krunal Nanavati
9769-919198
-Original Message-
From: Rui Barradas [mailto:ruipbarra...@sapo.pt]
Sent: 27 September 2012 21:55
To: Krunal Nanavati
Cc: David Winsemius; r-help@r-project.org
Subject: Re: [R] Running different Regressions using for loops
Hello,
Inline.
Em 27-09-20
(as.formula(fmla), data = tryout2)
}
The trick is to use ?expand.grid
Hope this helps,
Rui Barradas
I am not sure about its
placement...whether it should be in loop 2 or in loop 1
Can you please help me out??
Thanks & Regards,
Krunal Nanavati
9769-919198
-Original Message--
ith the" lm.list[[i]] <-
lm(as.formula(fmla), data = tryout)" statement. I am not sure about its
placement...whether it should be in loop 2 or in loop 1
Can you please help me out??
Thanks & Regards,
Krunal Nanavati
9769-919198
-Original Message-
From: Rui Barradas [m
erfectly.
In R there is a difference between expression objects and character objects.
Thanks & Regards,
Krunal Nanavati
9769-919198
*From:* Rui Barradas [mailto:ruipbarra...@sapo.pt]
*Sent:* 26 September 2012 17:13
*To:* Krunal Nanavati
*Cc:* r-help@r-project.org
*Subject:* Re: [R]
work perfectly.
In R there is a difference between expression objects and character objects.
> Thanks & Regards,
>
>
>
> Krunal Nanavati
>
> 9769-919198
>
>
>
> *From:* Rui Barradas [mailto:ruipbarra...@sapo.pt]
> *Sent:* 26 September 2012 17:13
&
To:* Krunal Nanavati
*Cc:* r-help@r-project.org
*Subject:* Re: [R] Running different Regressions using for loops
Hello,
Try the following.
#cnames <- names(tryout) # in your code, use this one
cnames <- c("Volume", "Price1", "Price2", "Price3", &q
Hello,
Try the following.
#cnames <- names(tryout) # in your code, use this one
cnames <- c("Volume", "Price1", "Price2", "Price3", "Price4", "Price5",
"Trend", "Seasonaliy")
price <- cnames[grep("Price", cnames)]
resp <- cnames[1]
regr <- cnames[7:8]
#lm.list <- vector("list", 5)
for(i in 1
Hi,
I am trying to run many different regressions using a FOR Loop.
The input data that is read into R has the following variables
· Volume
· Price1
· Price2
· Price3
· Price4
· Price5
· Trend
· Seasonality
I want to
16 matches
Mail list logo