Entry<Integer, Double> tempEntry;
Instance iExample;
int i = 0;
Instance originalCopy = getNewInstance(numAtts);
for (LinkedHashMap<Integer, Double> currentSample : trainingSamples) {
iExample = (Instance) originalCopy.copy();
iExample.setDataset(trainingSet);
currentIt = currentSample.entrySet().iterator();
while (currentIt.hasNext()) {
tempEntry = currentIt.next();
iExample.setValue(tempEntry.getKey(), tempEntry.getValue());