Just to clarify, the value you want to retrieve from, say,
[1, 7, 7, 10] is
7 is completely removed due to the fact that it appeared twice? Or are you looking for the number
6, because only the unique numbers are counted, and
7 is still included once? I believe you are looking for the former.
Though either way, the only way I can think of accomplishing this is by adjusting your data ingestion to add a field that tracks only numbers that are not duplicates, then you could use the normal average calculation on that field.
You can use a data table visualization to view unique values for a field, and export that data and run calculations externally on it, but I'm not aware of a way to use those unique numbers in a visualization inside Kibana.