added LDA class, wrapper refactor