fmicompbio / monaLisa

binned motif enrichment analysis and visualisation
https://fmicompbio.github.io/monaLisa/
GNU General Public License v3.0
36 stars 6 forks source link

Check homer run #25

Closed machlabd closed 5 years ago

machlabd commented 5 years ago

added internal function that check HOMER existing output files and if they ran correctly

machlabd commented 5 years ago

How the check works: .checkHomerRun will only return TRUE if the HOMER output files (knownResults.txt) exist and they are complete (all motifs in the motifFile are found in the txt file) and the number of knoenResults.txt files matches the number of bins specified in runHomer. I do not account for instances where the user may have extra knownResults.txt files (bigger than th enumber of bins..).

In runHomer, if .checkHomerRun passes, it uses the existing knownResults.txt files. Otherwise: 1) if there are txt files that have missing motifs or if the number of txt files does not equal the number of bins, it warns the user and asks to remove these files and rerun. 2) else: is runs HOMER from scratch