def na_padding(x, max_len, pad_offset = 0, na_value = "NA"):
    """
    Pads a list with NA's to achive a target length.
    """

    if len(x) < max_len:
        x = x[: -pad_offset] + (["NA" for i in range(max_len - len(x))]) + x[-pad_offset:]
        return x
    else:
        return x