added param for choosing method