Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

df apply not working as expected #628

Open
RahulDas-dev opened this issue Feb 23, 2024 · 0 comments
Open

df apply not working as expected #628

RahulDas-dev opened this issue Feb 23, 2024 · 0 comments

Comments

@RahulDas-dev
Copy link

Describe the bug
df apply not working as expected

To Reproduce
Here is the code for reproduce the bug

let data = {
    "text": ['THIS','IS', 'IN','UPPERCASE'],
    "count": [34, -4, 5, 0],
    "rank": [20, 2, 30, 8]
}
let df = new dfd.DataFrame(data)
df.print()

df['text'].apply(x => x.toLowerCase(), {inplace:true})  // It should change the df['text'] to upper case
df.print()

Expected behavior
df['colums'].apply(x => x +1 , {inplace:true}) should mutate the coulmn according to lambda in apply, but it is not doing so.

Screenshots
image

Desktop (please complete the following information):

  • OS: [Windows]
  • Browser [chrome]
  • Version [1.1.2]

Additional context

df['text'] = df['text'].apply(x =>x.toLowerCase()) working correctly.

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant