8504d7cd72e01e7a28601edb5d4c98c7c87a7849
braney
  Thu Nov 16 20:16:51 2017 -0800
add filtering to bigNarrowPeak

diff --git src/hg/lib/hui.c src/hg/lib/hui.c
index f28d8c1..fc73543 100644
--- src/hg/lib/hui.c
+++ src/hg/lib/hui.c
@@ -3554,31 +3554,31 @@
 	if (first)
 	    *first = atoi(a);
 	freeMem(a);
 	}
     if (b!=NULL)
 	{
 	if (second)
 	    *second = atoi(b);
 	freeMem(b);
 	}
     return TRUE;
     }
 return FALSE;
 }
 
-static boolean colonPairToDoubles(char * colonPair,double *first,double *second)
+boolean colonPairToDoubles(char * colonPair,double *first,double *second)
 { // Non-destructive. Only sets values if found. No colon: value goes to *first
 char *a=NULL;
 char *b=NULL;
 if (colonPairToStrings(colonPair,&a,&b))
     {
     if (a!=NULL)
 	{
 	if (first)
 	    *first = strtod(a,NULL);
 	freeMem(a);
 	}
     if (b!=NULL)
 	{
 	if (second)
 	    *second = strtod(b,NULL);
@@ -5489,31 +5489,31 @@
     if (deMin != NULL)
         *min = atoi(deMin);
     }
 // Defaulting min and max within limits.  Sorry for the horizontal ifs,
 // but stacking the group makes them easier to follow
 if (min && limitMin
 && *limitMin != NO_VALUE && (*min == NO_VALUE || *min < *limitMin)) *min = *limitMin;
 if (min && limitMax
 && *limitMax != NO_VALUE &&                      *min > *limitMax)  *min = *limitMax;
 if (max && limitMax
 && *limitMax != NO_VALUE && (*max == NO_VALUE || *max > *limitMax)) *max = *limitMax;
 if (max && limitMin
 && *limitMin != NO_VALUE &&                      *max < *limitMin)  *max = *limitMin;
 }
 
-static void getScoreFloatRangeFromCart(struct cart *cart, struct trackDb *tdb, boolean parentLevel,
+void getScoreFloatRangeFromCart(struct cart *cart, struct trackDb *tdb, boolean parentLevel,
                          char *scoreName, double *limitMin,double *limitMax,double*min,double*max)
 // gets an double score range from the cart, but the limits from trackDb
 // for any of the pointers provided, will return a value found, if found, else it's contents
 // are undisturbed (use NO_VALUE to recognize unavaliable values)
 {
 char scoreLimitName[128];
 char *deMin=NULL,*deMax=NULL;
 if ((limitMin || limitMax) && getScoreLimitsFromTdb(tdb,scoreName,NULL,&deMin,&deMax))
     {
     if (deMin != NULL && limitMin)
         *limitMin = strtod(deMin,NULL);
     if (deMax != NULL && limitMax)
         *limitMax =strtod(deMax,NULL);
     freeMem(deMin);
     freeMem(deMax);
@@ -6267,30 +6267,31 @@
                 extraWhere = dyAddFilterAsInt(cart,tdb,extraWhere,filter->name,"0:1000",field,and);
             else
                 extraWhere = dyAddFilterAsDouble(cart,tdb,extraWhere,filter->name,NULL,field,and);
             }
         slNameFree(&filter);
         }
     }
 return extraWhere;
 }
 
 boolean encodePeakHasCfgUi(struct trackDb *tdb)
 // Confirms that this track has encode Peak cfgUI
 {
 if (sameWord("narrowPeak",tdb->type)
 ||  sameWord("broadPeak", tdb->type)
+||  sameWord("bigNarrowPeak", tdb->type)
 ||  sameWord("encodePeak",tdb->type)
 ||  sameWord("gappedPeak",tdb->type))
     {
     return (trackDbSettingClosestToHome(tdb, SCORE_FILTER )
         ||  trackDbSettingClosestToHome(tdb, SIGNAL_FILTER)
         ||  trackDbSettingClosestToHome(tdb, PVALUE_FILTER)
         ||  trackDbSettingClosestToHome(tdb, QVALUE_FILTER)
         ||  trackDbSettingClosestToHome(tdb, SCORE_FILTER ));
     }
 return FALSE;
 }
 
 
 void encodePeakCfgUi(struct cart *cart, struct trackDb *tdb, char *name, char *title,
                      boolean boxed)