def check_dendrogram(dendrogram):
    """Check the shape of a dendrogram."""
    if dendrogram.ndim != 2 or dendrogram.shape[1] != 4:
        raise ValueError('Dendrogram has incorrect shape.')
    else:
        return
