'List EC2 instances in a cluster
:type cluster_id: str
:param cluster_id: The cluster id of interest
:type instance_group_id: str
:param instance_group_id: The EC2 instance group id of interest
:type instance_group_types: list
:param instance_group_types: Filter by EC2 instance group type
:type marker: str
:param marker: Pagination marker'

def list_instances(self, cluster_id, instance_group_id=None, instance_group_types=None, marker=None):

    params = {'ClusterId': cluster_id}
    if instance_group_id:
        params['InstanceGroupId'] = instance_group_id
    if marker:
        params['Marker'] = marker
    if instance_group_types:
        self.build_list_params(params, instance_group_types, 'InstanceGroupTypes.member')
    return self.get_object('ListInstances', params, InstanceList)
