making Scala class definitions more idiomatic
more idiomatic scala function
Typesetting for merged samples.