def filter_tweets(tweet_list, filter_retweets=True, filter_replies=True):
    """
        This method will filter tweets that are either retweets or replies.

        Args: 
            tweet_list (list): list of tweets
            filter_retweets (bool): switch for filtering retweets
            filter_replies (bool):  switch for filtering replies

        Returns:
            filtered list of tweets
    """
    filtered_list = []
    # Iterate over tweet list and apply conditions
    for t in tweet_list:
        conditions = []
        # Add retweet filter condition if selected
        if filter_retweets:
            conditions.append(
                (not t['retweeted']) and
                (t['full_text'][0:2] != 'RT'))
        # Add reply filter condition if selected
        if filter_replies:
            conditions.append(
                not t['in_reply_to_status_id'])
        # If filter_replies is set to False, method will return only replies
        else:
            conditions.append(
                t['in_reply_to_status_id'] is not None)

        # If all conditions met, add tweet to filtered list
        if sum(conditions) == len(conditions):
            filtered_list.append(t)

    return filtered_list