bc587fd886e5c5973d56b138aece47f34857e7eb markd Sat Oct 4 21:36:04 2025 -0700 added -bed option to bigWigToWig to selectively output wiggle regions (contributed by Michael Hiller) diff --git src/inc/bigWig.h src/inc/bigWig.h index 694d481dca3..ecee4aa6502 100644 --- src/inc/bigWig.h +++ src/inc/bigWig.h @@ -55,30 +55,37 @@ struct bbiFile *bigWigFileOpen(char *fileName); /* Open up big wig file. Free this up with bbiFileClose */ #define bigWigFileClose(a) bbiFileClose(a) struct bbiInterval *bigWigIntervalQuery(struct bbiFile *bwf, char *chrom, bits32 start, bits32 end, struct lm *lm); /* Get data for interval. Return list allocated out of lm. */ int bigWigIntervalDump(struct bbiFile *bwf, char *chrom, bits32 start, bits32 end, int maxCount, FILE *out); /* Print out info on bigWig parts that intersect chrom:start-end. Set maxCount to 0 if you * don't care how many are printed. Returns number printed. */ +int bigWigIntervalDumpWithName(struct bbiFile *bwf, char *chrom, bits32 start, bits32 end, int maxCount, char *name, + FILE *out); +/* Print out info on bigWig parts that intersect chrom:start-end. Set maxCount to 0 if you + * don't care how many are printed. Returns number printed. + Same as bigWigIntervalDump but passes the name parameter on to bigWigBlockDumpIntersectingRangeWithName + */ + boolean bigWigSummaryArray(struct bbiFile *bwf, char *chrom, bits32 start, bits32 end, enum bbiSummaryType summaryType, int summarySize, double *summaryValues); /* Fill in summaryValues with data from indicated chromosome range in bigWig file. * Be sure to initialize summaryValues to a default value, which will not be touched * for regions without data in file. (Generally you want the default value to either * be 0.0 or nan(0) depending on the application.) Returns FALSE if no data * at that position. */ boolean bigWigSummaryArrayExtended(struct bbiFile *bwf, char *chrom, bits32 start, bits32 end, int summarySize, struct bbiSummaryElement *summary); /* Get extended summary information for summarySize evenely spaced elements into * the summary array. */ double bigWigSingleSummary(struct bbiFile *bwf, char *chrom, int start, int end, enum bbiSummaryType summaryType, double defaultVal);