variants function

Constructor for the S4 variants object.