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

Prevent Untitled12.ipynb by adding pipe. #82

Merged
merged 1 commit into from
Sep 22, 2020
Merged
Changes from all 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
6 changes: 4 additions & 2 deletions py-polars/pypolars/frame.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
from __future__ import annotations
from .pypolars import PyDataFrame, PySeries
from typing import Dict, Sequence, List, Tuple, Optional, Union
from typing import Dict, Sequence, List, Tuple, Optional, Union, Callable, TextIO, BinaryIO
from .series import Series, wrap_s
from .datatypes import *
import numpy as np
from typing import TextIO, BinaryIO


def wrap_df(df: PyDataFrame) -> DataFrame:
Expand Down Expand Up @@ -341,6 +340,9 @@ def groupby(self, by: Union[str, List[str]]) -> GroupBy:
if isinstance(by, str):
by = [by]
return GroupBy(self._df, by)

def pipe(self, func: Callable, *args, **kwargs):
return func(self, *args, **kwargs)

def join(
self,
Expand Down