some refactoring and addition of analysis modules