return nan if no marginals are computed
only compute triangluar matrix for pairwise marginals
change back to temporary files
Merge pull request #5 from aaronkl/master

bugfixes