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

docs: fix broken link and update join documentation #29

Merged
merged 4 commits into from
Dec 26, 2022
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ Want to know about all the features Polars supports? Read the docs!
#### Node

* Installation guide: `$ yarn install nodejs-polars`
* [Node documentation](https://pola-rs.github.io/nodejs-polars/html/index.html)
* [Node documentation](https://pola-rs.github.io/nodejs-polars/)
* [User guide](https://pola-rs.github.io/polars-book/)

## Contribution
Expand Down
2 changes: 1 addition & 1 deletion polars/dataframe.ts
Original file line number Diff line number Diff line change
Expand Up @@ -702,7 +702,7 @@ export interface DataFrame
* @param options.on - Name(s) of the join columns in both DataFrames.
* @param options.how - Join strategy
* @param options.suffix - Suffix to append to columns with a duplicate name.
* @see {@link JoinOptions}
johanroelofsen marked this conversation as resolved.
Show resolved Hide resolved
* @see {@link JoinBaseOptions}
* @example
* ```
* >>> df = pl.DataFrame({
Expand Down
33 changes: 32 additions & 1 deletion polars/lazy/dataframe.ts
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,38 @@ export interface LazyDataFrame extends Serialize, GroupByOps<LazyGroupBy> {
*/
head(length?: number): LazyDataFrame;
/**
* Add a join operation to the Logical Plan.
* __SQL like joins.__
johanroelofsen marked this conversation as resolved.
Show resolved Hide resolved
* @param df - DataFrame to join with.
* @param options
* @param options.leftOn - Name(s) of the left join column(s).
* @param options.rightOn - Name(s) of the right join column(s).
* @param options.on - Name(s) of the join columns in both DataFrames.
* @param options.how - Join strategy
* @param options.suffix - Suffix to append to columns with a duplicate name.
* @see {@link LazyJoinOptions}
* @example
* ```
* >>> df = pl.DataFrame({
* >>> "foo": [1, 2, 3],
* >>> "bar": [6.0, 7.0, 8.0],
* >>> "ham": ['a', 'b', 'c']
* >>> })
* >>> otherDF = pl.DataFrame({
* >>> "apple": ['x', 'y', 'z'],
* >>> "ham": ['a', 'b', 'd']
* >>> })
* >>> df.join(otherDF, {on: 'ham', how: 'inner'})
* shape: (2, 4)
* ╭─────┬─────┬─────┬───────╮
* │ foo ┆ bar ┆ ham ┆ apple │
* │ --- ┆ --- ┆ --- ┆ --- │
* │ i64 ┆ f64 ┆ str ┆ str │
* ╞═════╪═════╪═════╪═══════╡
* │ 1 ┆ 6 ┆ "a" ┆ "x" │
* ├╌╌╌╌╌┼╌╌╌╌╌┼╌╌╌╌╌┼╌╌╌╌╌╌╌┤
* │ 2 ┆ 7 ┆ "b" ┆ "y" │
* ╰─────┴─────┴─────┴───────╯
* ```
*/
join(
other: LazyDataFrame,
Expand Down