collegebaseball/ncaa_scraper.py
def _format_names(original):
    """
    A helper function to turn names from "Last, First" to "First Last"
    
    Args: 
        original (str): the name to reformat. must be in form "Last, First"
    Returns: 
        str of format "First Last"
        
    Examples: 
        _format_names("Blumenfeld, Nathan")
        >>> "Nathan Blumenfeld"
    """
    try: 
        split = original.split(',')
        split.reverse()
        res = ' '.join(split).strip().title()
    except:
        res = np.nan
    return res

    A helper function to turn names from "Last, First" to "First Last"
    
    Args: 
        original (str): the name to reformat. must be in form "Last, First"
    Returns: 
        str of format "First Last"
        
    Examples: 
        _format_names("Blumenfeld, Nathan")
        >>> "Nathan Blumenfeld"
    
A helper function to turn names from "Last, First" to "First Last"
A helper function to turn names from " Last First " to " First Last "
def _format_names(original):
    try: 
        split = original.split(',')
        split.reverse()
        res = ' '.join(split).strip().title()
    except:
        res = np.nan
    return res
def _format_names ( original ) : try : split = original . split ( ',' ) split . reverse ( ) res = ' ' . join ( split ) . strip ( ) . title ( ) except : res = np . nan return res
A helper function to turn names from "Last, First" to "First Last"
A helper function to turn names from " Last First " to " First Last "
"""
    A helper function to turn names from "Last, First" to "First Last"
    
    Args: 
        original (str): the name to reformat. must be in form "Last, First"
    Returns: 
        str of format "First Last"
        
    Examples: 
        _format_names("Blumenfeld, Nathan")
        >>> "Nathan Blumenfeld"
    """
str of format "First Last"
str of format " First Last "
original
the name to reformat. must be in form "Last, First"
the name to reformat . must be in form " Last First "
examples
_format_names("Blumenfeld, Nathan")
>>> "Nathan Blumenfeld"
_format_names ( " Blumenfeld Nathan " ) >>> " Nathan Blumenfeld "