def is_package(name: str) ->bool:
    """Check if string maps to a package installed via pip.

    # Arguments
    name (str): Name of package.

    # Returns
    (bool): True if installed package, False if not.
    """
    import pkg_resources
    name = name.lower()
    packages = pkg_resources.working_set.by_key.keys()
    for package in packages:
        if package.lower().replace('-', '_') == name:
            return True
    return False
