Add a group to an existing group

ents = Sketchup.active_model.active_entities
found = ents.grep(Sketchup::Group).find {|g| == "MyGroup" }
if found
  clone = found.entities.add_instance(selectedGroup.definition,some_transform)
  clone.material= selectedGroup.material
  # If selectedGroup has attribute dictionaries you'll need
  # to iterate them and copy them to the new clone group.
  # Lastly, erase the source group:

Since I do not know anything about your groups, I have no idea how you wish to position the clone within the target group. You will need to produce some_transform to position the clone.

See: Geom::Transformation

FYI: [How to] Post correctly formatted and colorized code on the forum?