Skip to content

Conversation

ScottWilliamAnderson
Copy link
Contributor

Description of changes

ibis generally follows pandas syntax for mutating columns, with the exception of adding string columns where ibis.literal is needed. ibis.literal is not mentioned yet in the pandas' user introductions, so it would be helpful to include this as it's not clear to the user why adding a float column or summing two columns together uses the same syntax as pandas, while a adding a single-valued string column does not.

This is the reason #11009 was opened (as a q&a link to send to new users).

Including it in the pandas introduction docs would reduce friction for switching to ibis for pandas users.

@github-actions github-actions bot added the docs Documentation related issues or PRs label Mar 16, 2025
Copy link
Contributor

ACTION NEEDED

Ibis follows the Conventional Commits specification for release automation.

The PR title and description are used as the merge commit message.

Please update your PR title and description to match the specification.

See https://github.com/ibis-project/ibis/blob/main/.releaserc.js
for the list of acceptable prefixes, eg "feat:", "fix:", "chore:", etc.

The commitlint output is:

npm warn exec The following package was not found and will be installed: [email protected]
⧗   input: Add introduction to pandas users for adding columns with single text values (literal)

## Description of changes

ibis generally follows pandas syntax for mutating columns, with the exception of adding string columns where `ibis.literal` is needed. `ibis.literal` is not mentioned yet in the pandas' user introductions, so it would be helpful to include this as it's not clear to the user why adding a float column or summing two columns together uses the same syntax as pandas, while a adding a single-valued string column does not. 

This is the reason https://github.com/ibis-project/ibis/discussions/11009 was opened (as a q&a link to send to new users).

Including it in the pandas introduction docs would reduce friction for switching to ibis for pandas users.
✖   subject may not be empty [subject-empty]
✖   type may not be empty [type-empty]

✖   found 2 problems, 0 warnings
ⓘ   Get help: https://github.com/conventional-changelog/commitlint/#what-is-commitlint

@ScottWilliamAnderson ScottWilliamAnderson changed the title Add introduction to pandas users for adding columns with single text values (literal) docs: Add introduction to pandas users for adding columns with single text values (literal) Mar 16, 2025
@ScottWilliamAnderson
Copy link
Contributor Author

I think this is not needed, as recently the Getting Started docs now include introducing ibis.literal to the user:
#10918

@gforsyth gforsyth changed the title docs: Add introduction to pandas users for adding columns with single text values (literal) docs: add introduction to pandas users for adding columns with single text values (literal) Mar 16, 2025
@gforsyth
Copy link
Member

Hey @ScottWilliamAnderson! I think having this info in multiple places is fine -- users coming from pandas might very well skip the "Getting Started" guide in favor of the "Coming from pandas" guide.

@ScottWilliamAnderson
Copy link
Contributor Author

Hey @ScottWilliamAnderson! I think having this info in multiple places is fine -- users coming from pandas might very well skip the "Getting Started" guide in favor of the "Coming from pandas" guide.

Ah, great to hear. I've re-opened the PR, you can merge this if you find it helpful.

Copy link
Member

@gforsyth gforsyth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@gforsyth gforsyth merged commit 6032e71 into ibis-project:main Mar 16, 2025
58 checks passed
@ScottWilliamAnderson ScottWilliamAnderson deleted the improved-scalar-col-for-pandas-docs branch March 16, 2025 22:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Documentation related issues or PRs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants