Double max = volist.stream().map(vo -> modellist .stream()
.collect(Collectors.averagingDouble(model ->
jarowinklerdistance.apply(model.getCity(), vo.getCity())))
).max(Double::compare).get();
System.out.println(max);
.collect(Collectors.averagingDouble(model ->
jarowinklerdistance.apply(model.getCity(), vo.getCity())))
).max(Double::compare).get();
System.out.println(max);
No comments:
Post a Comment