jiabowang / GAPIT

Genome Association Predict Integrate Tools
158 stars 52 forks source link

"Perform numericalization": Error in count.temp[, 2] : subscript out of bounds #131

Open PollyRosy opened 2 months ago

PollyRosy commented 2 months ago

Hello. I encountered a very basic problem but I do not know how to fix it. I would appreciate it if you could help me. Thanks in advance. In my hapmap files, which converted from vcf, there are 2 nucleotide acids (bit=2?) and there are some multiallelic sites, but I removed them manually for now. I converted the vcf to Hapmap using the following way: https://github.com/wenkaiyan-kevin/vcf-to-hapmap.

I think there must be something wrong happening on data input?

myGAPIT <- GAPIT(Y=myacc,G=myG) [1] "--------------------- Welcome to GAPIT ----------------------------" [1] "MLM" [1] "--------------------Processing traits----------------------------------" [1] "Phenotype provided!" [1] "The 1 model in all." [1] "MLM" [1] "GAPIT.DP in process..." [1] "Converting genotype..." [1] "Converting HapMap format to numerical under model of Middle" [1] "Perform numericalization" Error in count.temp[, 2] : subscript out of bounds

Screenshot from 2024-06-25 15-46-15 Screenshot from 2024-06-25 15-45-43

yaoxkkkkk commented 1 month ago

I met the same error too, have you solved it?

I think it's version issue, when I use lower version everything goes well. @jiabowang Could you check this problem?

PollyRosy commented 1 month ago

Instead of hapmap. I converted to ped and map using plink.

Lightoscope commented 1 month ago

Instead of hapmap. I converted to ped and map using plink.

This is what I did too.

yaoxkkkkk commented 1 month ago

OK then. I think it would work when there only SNP exits because plink does not support INDEL, which I intend to keep in my GWAS analysis ;)

jiabowang commented 1 month ago

Hi all, I have fixed this error. Please try again with new GAPIT function.

Lightoscope commented 1 month ago

Hi all, I have fixed this error. Please try again with new GAPIT function.

Where is the new GAPIT function? The file at https://zzlab.net/GAPIT/gapit_functions.txt says it's version 3.4.

jiabowang commented 1 month ago

The function in zzlab has not been updated. Please try this one.

gapit_functions.txt

jiabowang commented 1 month ago

The version is not changed. The current version is 3.4.

yaoxkkkkk commented 1 month ago

The function in zzlab has not been updated. Please try this one.

gapit_functions.txt

Hi, I used this script, but it still output the error: image

jiabowang commented 1 month ago

Could you send me the genotype file?

Xiukun Yao @.***> 于2024年7月19日周五 22:54写道:

The function in zzlab has not been updated. Please try this one.

gapit_functions.txt https://github.com/user-attachments/files/16310042/gapit_functions.txt

Hi, I used this script, but it still output the error: image.png (view on web) https://github.com/user-attachments/assets/b1a0204d-068a-459f-8f5b-8f58b7cfac88

— Reply to this email directly, view it on GitHub https://github.com/jiabowang/GAPIT/issues/131#issuecomment-2239400430, or unsubscribe https://github.com/notifications/unsubscribe-auth/AH5SAH4Q7FGB3EG7LOC3HQ3ZNESAXAVCNFSM6AAAAABJ3563RWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMZZGQYDANBTGA . You are receiving this because you were mentioned.Message ID: @.***>

ceciliabruno commented 3 weeks ago

Hello,

I update GAPIT version 3.4.0 and introduce the gapit_functions.txt. Hovewer I still have a problem.

[1] "--------------------- Welcome to GAPIT ----------------------------" [1] "MLM" [1] "--------------------Processing traits----------------------------------" [1] "Phenotype provided!" [1] "The 1 model in all." [1] "MLM" [1] "GAPIT.DP in process..." [1] "Converting genotype..." [1] "Converting HapMap format to numerical under model of Middle" [1] "Perform numericalization" Error in count.temp[, 2] : subscript out of bounds

Thank you Cecilia

jiabowang commented 2 weeks ago

@ceciliabruno Please check your HapMap file whether there are different symbols for missing genotype.

ceciliabruno commented 2 weeks ago

@ceciliabruno Please check your HapMap file whether there are different symbols for missing genotype.

Hello, Thank you for your answer. I reviewed the HapMap file and I solved the problem. Currently, I have another problem with " Manhattan plot (Genowise)...".

[1] "Manhattan plot (Genomewise)..." Error in seq.default(1, nchr, by = ncycle) : invalid '(to - from)/by' In addition: Warning messages: 1: In rm(eig.L) : object 'eig.L' not found 2: In order(as.numeric(GWAS[, 3])) : NAs introduced by coercion 3: In matrix(as.numeric(as.matrix(GI.MP)), nrow(GI.MP), ncol(GI.MP)) : NAs introduced by coercion 4: In min(spd) : no non-missing arguments to min; returning Inf 5: In max(GI.MP[, 3]) : no non-missing arguments to max; returning -Inf 6: In max(GI.MP[, 1]) : no non-missing arguments to max; returning -Inf

  Thank you Cecilia

jiabowang commented 2 weeks ago

How many chromosomes are in your genotype file?

ceciliabruno commented 2 weeks ago

How many chromosomes are in your genotype file?

Hello,

There are 8 chromosomes in the genotype file. Thank you Cecilia

jiabowang commented 2 weeks ago

@ceciliabruno , Please check your genotype file or you can sent it with me. I can help with checking.