Changed format of output
Decomposition of analyze method