Closed laduplessis closed 4 years ago
Better late than never! The commit looks sensible; after all, what's the point of continuing with an analysis after a warning like "this analysis is not valid"?
Just a comment on the checking code itself though - it looks very fragile. This check could conclude that the operators are unsuitable even when they are if SA-specific operators extended any of the operators in the hard-coded list. Conversely, the check could conclude that the operators are suitable when they're not, if non SA-specific tree operators are being used which are not on that list.
But I suppose the intent here is to catch the majority of the problems - people writing their own tree operators are capable of submitting pull requests. :-)
Current behaviour when running a sampled ancestors analysis without using sampled ancestor tree operators is to print an error message stating the analysis is not valid and continue running. The error message is printed in between other initialisation output and will probably not be noticed by many users. If the analysis is not valid the error should be fatal and the program should refuse to run.