Finalized analyzer, needs debugging