minor fixes
Completed the analyse function. Output of structured thread data is possible, though it's slow.