import math


def rotate_y_at_origin(vector, value, value_in_radians = False):
    """
    Rotate a vector around its y axis.
    
    Args:
        vector (list): 3 value list
        value (float): amount to rotate
        value_in_radians (bool): If the value is in radians, if not in degrees.
        
    Return:
        list: 3 value list that is the result of the rotation.
    """
    if not value_in_radians:
        value = math.radians(value)
    
    x = ( vector[0]*math.cos(value) ) + ( vector[2]*math.sin(value) )
    y = vector[1]
    z = ( -(vector[0]*math.sin(value)) ) + ( vector[2]*math.cos(value) )
    
    
    return [x,y,z]