5dd57ba4756985d35f8ca72756d963b77934fcf0 angie Thu Jun 7 16:08:53 2018 -0700 Expand support for -multiple to BED 3 to 12 (instead of 4 to 6). refs #18853 Added a -noSerial option to prevent -multiple from forcing the score field to contain a serial number for BED without blocks. Also fixed a bug with the loop on chains overwriting args thickStart and thickEnd. Todo: genePred. Probably won't bother doing PSL because pslMap should be used for that. Also removed some very old #ifdef'd code. diff --git src/hg/inc/liftOver.h src/hg/inc/liftOver.h index 8626354..9303e3e 100644 --- src/hg/inc/liftOver.h +++ src/hg/inc/liftOver.h @@ -34,65 +34,65 @@ /* Get list of all liftOver chains in the central database for fromDb, * filtered to include only those chains whose liftover files exist. */ char *liftOverChainFile(char *fromDb, char *toDb); /* Get filename of liftOver chain */ enum liftOverFileType liftOverSniff(char *fileName); /* the file-sniffing bit used to distinguish bed from positions files */ /* returns enum concerning the file type */ int liftOverBed(char *fileName, struct hash *chainHash, double minMatch, double minBlocks, int minSizeT, int minSizeQ, int minChainT, int minChainQ, bool fudgeThick, FILE *f, FILE *unmapped, - bool multiple, char *chainTable, int *errCt); + bool multiple, bool noSerial, char *chainTable, int *errCt); /* Open up file, decide what type of bed it is, and lift it. * Return the number of records successfully converted */ int liftOverBedPlus(char *fileName, struct hash *chainHash, double minMatch, double minBlocks, int minSizeT, int minSizeQ, int minChainT, int minChainQ, bool fudgeThick, FILE *f, FILE *unmapped, - bool multiple, char *chainTable, int bedPlus, bool hasBin, + bool multiple, bool noSerial, char *chainTable, int bedPlus, bool hasBin, bool tabSep, int *errCt); /* Lift bed with N+ (where n=bedPlus param) format. * Return the number of records successfully converted */ int liftOverBedPlusEnds(char *fileName, struct hash *chainHash, double minMatch, double minBlocks, int minSizeT, int minSizeQ, int minChainT, int minChainQ, bool fudgeThick, FILE *f, FILE *unmapped, - bool multiple, char *chainTable, int bedPlus, bool hasBin, + bool multiple, bool noSerial, char *chainTable, int bedPlus, bool hasBin, bool tabSep, int ends, int *errCt); /* Lift bed N+ file. * Return the number of records successfully converted */ int liftOverPositions(char *fileName, struct hash *chainHash, double minMatch, double minBlocks, int minSizeT, int minSizeQ, int minChainT, int minChainQ, bool fudgeThick, FILE *f, FILE *unmapped, bool multiple, char *chainTable, int *errCt); /* Create bed file from positions (chrom:start-end) and lift. * Return the number of records successfully converted */ int liftOverBedOrPositions(char *fileName, struct hash *chainHash, double minMatch, double minBlocks, int minSizeT, int minSizeQ, int minChainT, int minChainQ, bool fudgeThick, FILE *mapped, FILE *unmapped, - bool multiple, char *chainTable, int *errCt); + bool multiple, bool noSerial, char *chainTable, int *errCt); /* Sniff the first line of the file, and determine whether it's a */ /* bed, a positions file, or neither. */ char *liftOverRemapRange(struct hash *chainHash, double minRatio, char *chrom, int s, int e, char strand, double minMatch, char **retChrom, int *retStart, int *retEnd, char *retStrand); /* Remap a range through chain hash. If all is well return NULL * and results in retChrom, retStart, retEnd. Otherwise * return a string describing the problem. */ void liftOverGff(char *fileName, struct hash *chainHash, double minMatch, double minBlocks, FILE *mapped, FILE *unmapped); /* Lift over GFF file */