Set reference index when setting a new feature stack.

To prevent the bug fixed on this commit:

https://github.com/fiji/Trainable_Segmentation/commit/f68b26e1bb98579556e51d37c1933704fc447fce

We needed to create a public method to set the reference index and use it to set the reference to the stack slice with traces before the training.