c28ad38574430f9e09967086b7ea4cd45edc7e19 angie Tue Jan 11 15:22:55 2011 -0800 Some more polishing for SNP details. diff --git src/hg/hgc/hgc.c src/hg/hgc/hgc.c index 54ebb4b..c63c225 100644 --- src/hg/hgc/hgc.c +++ src/hg/hgc/hgc.c @@ -15648,31 +15648,31 @@ snp->chromStart, snp->chromEnd); struct genePred *gene; char query[256]; char buf[256]; safef(query, sizeof(query), "select shortLabel from trackDb where tableName='%s'", gt->name); char *shortLabel = sqlQuickQuery(conn, query, buf, sizeof(buf)-1); if (shortLabel == NULL) shortLabel = gt->name; for (gene = geneList; gene != NULL; gene = gene->next) printSnp125FunctionInGene(snp, gt->name, shortLabel, gene); if (geneList == NULL) printSnp125NearGenes(conn, snp, gt->name, shortLabel); first = FALSE; } if (! first) - printf("
\n"); + printf("\n"); hFreeConn(&conn); } char *dbSnpFuncFromInt(unsigned char funcCode) /* Translate an integer function code from NCBI into an abbreviated description. * Do not free return value! */ // Might be a good idea to flesh this out with all codes, libify, and share with // snpNcbiToUcsc instead of partially duplicating. { switch (funcCode) { case 3: return "coding-synon"; case 8: return "cds-reference"; @@ -15781,31 +15781,31 @@ total2N = round(n / f); int roundedN = round(n); if (fabs(n - roundedN) < 0.01) printf("(%d / %d)", roundedN, total2N); else { gotNonIntN = TRUE; printf("(%.3f / %d)", n, total2N); } } } printf("\n"); if (gotNonIntN) printf(" Note: dbSNP extrapolates allele counts from reported frequencies and " "reported 2N sample sizes (total %d); non-integer allele count may imply " - "a problem with one of the reported numbers.\n", total2N); + "an inaccuracy in one of the reported numbers.
\n", total2N); } else puts(""); if (isNotEmpty(snp->bitfields) && differentString(snp->bitfields, "unknown")) { printf("
Miscellaneous properties annotated by dbSNP:" "\n\n"); struct slName *bitfields = slNameListFromComma(snp->bitfields); if (slNameInList(bitfields, "clinically-assoc")) printf("
***clinically associated*** " "(SNP is in OMIM/OMIA and/or " "at least one submitter is a Locus-Specific Database)\n"); if (slNameInList(bitfields, "has-omim-omia")) printf("
SNP is in OMIM/OMIA\n"); if (slNameInList(bitfields, "microattr-tpa")) @@ -16190,38 +16190,39 @@ errAbort("SNP %s not found at %s base %d", itemName, seqName, start); sqlFreeResult(&sr); safef(query, sizeof(query), "select * from %s where name='%s'", table, itemName); sr = sqlGetResult(conn, query); while ((row = sqlNextRow(sr)) != NULL) { if (version >= 132) snp = snp132ExtLoad(row+rowOffset); else snp = (struct snp132Ext *)snp125Load(row+rowOffset); if (snp->chromStart != start || differentString(snp->chrom, seqName)) { if (snpCount==0) - printf("This SNP maps to these additional locations:" + printf("
This SNP maps to these additional locations:" "

"); snpCount++; bedPrintPos((struct bed *)snp, 3, tdb); printf("
"); } } sqlFreeResult(&sr); +puts("
"); // Make table for collapsible sections: puts(""); checkForGwasCatalog(conn, tdb, itemName); checkForHgdpGeo(conn, tdb, itemName, start); checkForHapmap(conn, tdb, itemName); checkForLsSnpMappings(conn, tdb->track, itemName); printSnpAlignment(tdb, snpAlign); puts("
"); printTrackHtml(tdb); hFreeConn(&conn); } void doTigrGeneIndex(struct trackDb *tdb, char *item) /* Put up info on tigr gene index item. */