LSD-test

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

LSD-test

Ahmed Attia
LSD-test produces error for this code;

code <- as.factor(Rotationdata_R$`Rot/code`)  #factor in the main
Nitrogen <- as.factor(Rotationdata_R$Nitrogen) #factor in the sub
Rep <- as.factor(Rotationdata_R$REP) #blocks
Year <- as.factor(Rotationdata_R$YEAR)  #years

model <- aov(Rotationdata_R$`GY(Mg/ha)`~Rep+code*as.factor(Nitrogen)+Error(Rep/Year/code),data=Rotationdata_R)
summary(model)

LSD.test(y=model,trt="code",console=TRUE)

the error;

Error in as.data.frame.default(x[[i]], optional = TRUE,
stringsAsFactors = stringsAsFactors) :
  cannot coerce class "c("aovlist", "listof")" to a data.frame

What is wrong with this.



Ahmed Attia, Ph.D.
Agronomist & Soil Scientist

______________________________________________
[hidden email] mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|

Re: LSD-test

David Winsemius

> On Dec 25, 2017, at 10:21 AM, Ahmed Attia <[hidden email]> wrote:
>
> LSD.test

?LSD.test
No documentation for ‘LSD.test’ in specified packages and libraries:
you could try ‘??LSD.test’

--
David Winsemius
Alameda, CA, USA

'Any technology distinguishable from magic is insufficiently advanced.'   -Gehm's Corollary to Clarke's Third Law

______________________________________________
[hidden email] mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|

Re: LSD-test

Ahmed Attia
The model should be class aov or lm and my model class is aovlist.
tried tidy from broom library but did not work. To make it class aov,
I had to remove the error term;

model <- aov(Rotationdata_R$`GY(Mg/ha)`~Rep+code*as.factor(Nitrogen),data=Rotationdata_R)
Ahmed Attia, Ph.D.
Agronomist & Soil Scientist






On Mon, Dec 25, 2017 at 7:38 PM, David Winsemius <[hidden email]> wrote:

>
>> On Dec 25, 2017, at 10:21 AM, Ahmed Attia <[hidden email]> wrote:
>>
>> LSD.test
>
> ?LSD.test
> No documentation for ‘LSD.test’ in specified packages and libraries:
> you could try ‘??LSD.test’
>
> --
> David Winsemius
> Alameda, CA, USA
>
> 'Any technology distinguishable from magic is insufficiently advanced.'   -Gehm's Corollary to Clarke's Third Law
>
>
>
>
>

______________________________________________
[hidden email] mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|

Re: LSD-test

David Winsemius

> On Dec 25, 2017, at 2:09 PM, Ahmed Attia <[hidden email]> wrote:
>
> The model should be class aov or lm and my model class is aovlist.
> tried tidy from broom library but did not work. To make it class aov,
> I had to remove the error term;
>
> model <- aov(Rotationdata_R$`GY(Mg/ha)`~Rep+code*as.factor(Nitrogen),data=Rotationdata_R)

You seemed to have missed my point that LSD.test is not in the packages loaded by default.


> Ahmed Attia, Ph.D.
> Agronomist & Soil Scientist
>
>
>
>
>
>
> On Mon, Dec 25, 2017 at 7:38 PM, David Winsemius <[hidden email]> wrote:
>>
>>> On Dec 25, 2017, at 10:21 AM, Ahmed Attia <[hidden email]> wrote:
>>>
>>> LSD.test
>>
>> ?LSD.test
>> No documentation for ‘LSD.test’ in specified packages and libraries:
>> you could try ‘??LSD.test’
>>
>> --
>> David Winsemius
>> Alameda, CA, USA
>>
>> 'Any technology distinguishable from magic is insufficiently advanced.'   -Gehm's Corollary to Clarke's Third Law
>>
>>
>>
>>
>>

David Winsemius
Alameda, CA, USA

'Any technology distinguishable from magic is insufficiently advanced.'   -Gehm's Corollary to Clarke's Third Law

______________________________________________
[hidden email] mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|

Re: LSD-test

Kenneth Roy Cabrera Torres
Check the agricolae package.


library(agricolae)


El 25/12/17 a las 17:33, David Winsemius escribió:

>> On Dec 25, 2017, at 2:09 PM, Ahmed Attia <[hidden email]> wrote:
>>
>> The model should be class aov or lm and my model class is aovlist.
>> tried tidy from broom library but did not work. To make it class aov,
>> I had to remove the error term;
>>
>> model <- aov(Rotationdata_R$`GY(Mg/ha)`~Rep+code*as.factor(Nitrogen),data=Rotationdata_R)
> You seemed to have missed my point that LSD.test is not in the packages loaded by default.
>
>
>> Ahmed Attia, Ph.D.
>> Agronomist & Soil Scientist
>>
>>
>>
>>
>>
>>
>> On Mon, Dec 25, 2017 at 7:38 PM, David Winsemius <[hidden email]> wrote:
>>>> On Dec 25, 2017, at 10:21 AM, Ahmed Attia <[hidden email]> wrote:
>>>>
>>>> LSD.test
>>> ?LSD.test
>>> No documentation for ‘LSD.test’ in specified packages and libraries:
>>> you could try ‘??LSD.test’
>>>
>>> --
>>> David Winsemius
>>> Alameda, CA, USA
>>>
>>> 'Any technology distinguishable from magic is insufficiently advanced.'   -Gehm's Corollary to Clarke's Third Law
>>>
>>>
>>>
>>>
>>>
> David Winsemius
> Alameda, CA, USA
>
> 'Any technology distinguishable from magic is insufficiently advanced.'   -Gehm's Corollary to Clarke's Third Law
>
> ______________________________________________
> [hidden email] mailing list -- To UNSUBSCRIBE and more, see
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.

______________________________________________
[hidden email] mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.