我试图在名为float(64)的数据文件中的一个名为date_of_birth的列中使用一些零填充drugs_tall值。date_of_birth包含一些NA。AttributeError: 'DataFrame' object has no attribute 'str'drugs_tall.locAttributeError: Can only use .str accessor with string value
我已经签出了map、apply、mapapply和组合,但似乎找不到一种简单的方法来执行以下操作:some_func(int a, int b, int c) returns int d
我想应用这一点,并在dataframe中创建一个新列df['d'] = some_func(a = df['a'], b = df['b'], c =