SJTU-CGM / HUPAN

Human pan-genome analysis pipeline
http://cgm.sjtu.edu.cn/hupan/
29 stars 6 forks source link

Uninitialized value $1 and $pre_gid error with `pTpG` function #7

Closed Boer223 closed 4 years ago

Boer223 commented 4 years ago

Hi, Dr. Duan,

When I run hupan pTpG to retrieve ptpg.gtf from my gtf file, it occurs some error with some variables in HUPANpTpG.pm, like this :

Use of uninitialized value $pre_gid in string eq at /home/cuixb/tools/biosoft/EUPAN/lib//EUPANpTpG.pm line 111, <IN> line 3091.
Use of uninitialized value $2 in string eq at /home/cuixb/tools/biosoft/EUPAN/lib//EUPANpTpG.pm line 112, <IN> line 3091.

My gtf file:

chrA01  maker   transcript      130     2690    .       -       .       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   exon    130     290     .       -       .       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   exon    315     727     .       -       .       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   exon    827     1078    .       -       .       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   exon    1147    1408    .       -       .       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   exon    1546    1634    .       -       .       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   exon    1718    2014    .       -       .       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   exon    2108    2164    .       -       .       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   exon    2276    2414    .       -       .       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   exon    2512    2621    .       -       .       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   exon    2642    2690    .       -       .       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   CDS     371     727     .       -       0       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   CDS     827     1078    .       -       0       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   CDS     1147    1408    .       -       1       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   CDS     1546    1634    .       -       0       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   CDS     1718    2014    .       -       0       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   CDS     2108    2164    .       -       0       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   CDS     2276    2414    .       -       1       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   CDS     2512    2621    .       -       0       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";
chrA01  maker   CDS     2642    2674    .       -       0       transcript_id "ZS11A01G000010-mRNA-1"; gene_id "ZS11A01G000010";

So, do you have some suggestions? Thank you!

zhqduan commented 4 years ago

Hi, In gff or gtf file, gene_id is generally put before transcript_id, so please change your gtf file like this: chrA01 maker transcript 130 2690 . - . gene_id "ZS11A01G000010"; transcript_id "ZS11A01G000010-mRNA-1"; chrA01 maker exon 130 290 . - . gene_id "ZS11A01G000010"; transcript_id "ZS11A01G000010-mRNA-1"; ... Hope it works!

Boer223 commented 4 years ago

Yeah, I have changed the gtf file colum and it works well, thank you for your reply!