更新时间:2023-02-12 19:24:08
与 Mr. Me 类似,这将删除前 6 个字符之前的所有内容,并将它们替换为您的新格式.
Similar to Mr. Me, this will instead remove everything before the first 6 characters and replace them with your new format.
emp_pd["SSN"] = emp_pd["SSN"].apply(lambda x: "***-**" + x[6:])