Bug fixes
Bug fixes: sample ordering