Print

Print


Hi Ustav,

I couldn't get a working copy of asreml package, and the one that I installed doesn't have asreml.ped attach to it. It would be great if there's a help page of the function.

My best guess is your data$Male is numeric or character. You might want to try: "data$Male <- as.factor(data$Male)" and rerun the asreml.ped and see if you get the same error.

Ben

´╗┐On 26/4/18, 1:24 PM, "UF R Users List on behalf of Kumar,Utsav" <[log in to unmask] on behalf of [log in to unmask]> wrote:

    Hi R-Gators,
    
    
    I'm trying to estimate heratibility by including pedigree. I did the same analysis w/o pedigree and it was working well but after adding pedigree when i do same analysis. I get this error:
    
    
    Error in asreml.ped(Male, data = data, Rcov = 0) :
      Argument to ped() must be a factor)
    
    
    And i have used below code:
    
    
    library(asreml)
    ainvpar<-asreml.Ainverse(ped_citra_s17)$ginv
    
    model1<-asreml(fixed = First.Ear.Position~Rep,
                          random = ~ped(Female)+and(ped(Male))+Genotype.ID,
                          ginverse=list(Male=ainvpar,Female=ainvpar),
                          data = Citra_s17, na.method.X = "include")
    
    Can anyone please tell me where am i going wrong or what does this error mean?
    
    Thanks in advance.
    
    This list strives to be beginner friendly.  However, we still ask that you
    PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
    and provide commented, minimal, self-contained, reproducible code.
    

This list strives to be beginner friendly.  However, we still ask that you
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.