How to apply a self defined function in Pandas
Shaozhong SHI
shishaozhong at gmail.com
Sun Oct 31 16:08:49 EDT 2021
On Sun, 31 Oct 2021 at 18:42, Shaozhong SHI <shishaozhong at gmail.com> wrote:
>
>
> On Sunday, 31 October 2021, Albert-Jan Roskam <sjeik_appie at hotmail.com>
> wrote:
>
>>
>>
>> > df['URL'] = df.apply(lambda x: connect(df['URL']), axis=1)
>>
>>
>> I think you need axis=0. Or use the Series, df['URL'] =
>> df.URL.apply(connect)
>>
>
> Just experimented with your suggestion, but have not seen any difference.
>
Regards, David
More information about the Python-list
mailing list