eeb6e13f3c9d1f3e9883b76498f5cb1a80463531 markd Mon Aug 16 23:41:36 2010 -0700 fix bug where insertions between multiple bases of stop codon generated incorrect frame. Provide explicit control over use of gene_id or gene_name for name2 column diff --git src/utils/gtfToGenePred/gtfToGenePred.c src/utils/gtfToGenePred/gtfToGenePred.c index 36df762..b2acca1 100644 --- src/utils/gtfToGenePred/gtfToGenePred.c +++ src/utils/gtfToGenePred/gtfToGenePred.c @@ -22,7 +22,9 @@ " -infoOut=file - write a file with information on each transcript\n" " -sourcePrefix=pre - only process entries where the source name has the\n" " specified prefix. May be repeated.\n" - " -impliedStopAfterCds - implied stop codon in after CDS\n"); + " -impliedStopAfterCds - implied stop codon in after CDS\n" + " -geneNameAsName2 - if specified, use gene_name for the name2 field\n" + " instead of gene_id.\n"); } static struct optionSpec options[] = { @@ -31,6 +33,7 @@ {"infoOut", OPTION_STRING}, {"sourcePrefix", OPTION_STRING|OPTION_MULTI}, {"impliedStopAfterCds", OPTION_BOOLEAN}, + {"geneNameAsName2", OPTION_BOOLEAN}, {NULL, 0}, }; boolean clGenePredExt = FALSE; /* include frame and geneName */ @@ -175,6 +178,8 @@ clSourcePrefixes = optionMultiVal("sourcePrefix", NULL); if (optionExists("impliedStopAfterCds")) clGxfOptions |= genePredGxfImpliedStopAfterCds; +if (optionExists("geneNameAsName2")) + clGxfOptions |= genePredGxfGeneNameAsName2; gtfToGenePred(argv[1], argv[2], optionVal("infoOut", NULL)); if (badGroupCount > 0)