reduce by selection