def METHOD_NAME(fn):
    ''' Reads positions from a .csv file
    Parameters
    ------------
    fn: str
        Name of csv file
    Returns
    --------
    type: list
        Type of position in each row ('Generic', 'Fiducial', 'Electrode', 'ReferenceElectrode' or
        'Coil')
    coordinates: list
        Coordinates in each row
    extra: list
        extra coordinates in each row (eg: electrode or coil axes)
    name: list
        Name of position
    extra_cols: list
        Any extra information stored in the columns
    header: str
        Any information in the header
    '''
    with open(os.path.expanduser(fn), 'r') as f:
        reader = csv.reader(f)
        rows = [row for row in reader]
    if len(rows[-1]) < 3:
        raise IOError('CSV file must have at least 4 rows')
    coordinates = []
    try:
        float(rows[0][1])
        header = []
        start = 0
    except:
        header = rows[0]
        start = 1
    rows = rows[start:]
    type_ = [r[0] for r in rows]
    extra = []
    name = []
    extra_cols = []
    type_filtered = []
    rows_filtered = []
    for t, r, i in zip(type_, rows, range(len(type_))):
        if t in ['Generic', 'Fiducial'] or len(r) == 4:
            name += [r[4] if len(r) >= 5 else None]
            extra_cols += [r[5:] if len(r) > 5 else None]
            extra += [None]
            type_filtered.append(t)
            rows_filtered.append(r)
        elif t in ['Electrode', 'ReferenceElectrode']:
            try:
                extra_ = np.array(r[4:7], float)
                assert len(extra_) == 3
                extra += [extra_]
                name += [r[7] if len(r) >= 8 else None]
                extra_cols += [r[8:] if len(r) > 8 else None]
            except:
                extra += [None]
                name += [r[4] if len(r) >= 5 else None]
                extra_cols += [r[5:] if len(r) > 5 else None]
            type_filtered.append(t)
            rows_filtered.append(r)
        elif t == 'CoilPos':
            extra += [np.array([float(d) for d in r[4:11]])]
            name += [r[11] if len(r) >= 12 else None]
            extra_cols += [r[12:] if len(r) > 12 else None]
            type_filtered.append(t)
            rows_filtered.append(r)
        else:
            warnings.warn('Unrecognized column type: {0}'.format(t))
    type_ = type_filtered
    rows = rows_filtered
    try:
        coordinates = np.array(
            [[float(d) for d in r[1:4]] for r in rows],
            dtype=float)
    except:
        raise IOError('Could not read coordinates from CSV file')
    return type_, coordinates, extra, name, extra_cols, header