Skip to content
New issue

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

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

Already on GitHub? # to your account

Changed: extract pandas DataFrame converter into a separate module, changed data.add_data_frame methods to data.add_df #252

Merged
merged 17 commits into from
Aug 2, 2023
Merged
Show file tree
Hide file tree
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
8 changes: 1 addition & 7 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -130,12 +130,6 @@ jobs:
path: .venv
key: cache_dev_py_ubuntu22_${{ hashFiles('pdm.lock') }}

- name: Cache package
uses: actions/cache@v3
with:
path: dist/
key: cache_package_${{ github.run_id }}

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
Expand All @@ -151,7 +145,7 @@ jobs:
"3.10") python_test_env="py310";;
"3.11") python_test_env="py311";;
esac
pdm run test -e "${python_test_env}" --installpkg dist/*.whl
pdm run test -e "${python_test_env}"

- name: Cache coverage
if: startsWith(matrix.python-version, '3.10')
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ df = pd.read_csv(
"https://ipyvizzu.vizzuhq.com/latest/showcases/titanic/titanic.csv"
)
data = Data()
data.add_data_frame(df)
data.add_df(df)

chart = Chart(width="640px", height="360px")

Expand Down
4 changes: 2 additions & 2 deletions community/color-blindness_theme.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,12 @@
"\n",
"# Create data object, read csv to data frame and add data frame to data object.\n",
"data = Data()\n",
"data_frame = pd.read_csv(\n",
"df = pd.read_csv(\n",
" \"https://raw.githubusercontent.com/vizzuhq/ipyvizzu/\"\n",
" + \"gh-pages/docs/data/chart_types_eu.csv\",\n",
" dtype={\"Year\": str, \"Timeseries\": str},\n",
")\n",
"data.add_data_frame(data_frame)"
"data.add_df(df)"
]
},
{
Expand Down
4 changes: 2 additions & 2 deletions community/dark_theme.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@
"\n",
"# Create data object, read csv to data frame and add data frame to data object.\n",
"data = Data()\n",
"data_frame = pd.read_csv(\n",
"df = pd.read_csv(\n",
" \"https://raw.githubusercontent.com/vizzuhq/ipyvizzu/\"\n",
" + \"gh-pages/docs/data/chart_types_eu.csv\",\n",
" dtype={\"Year\": str, \"Timeseries\": str},\n",
")\n",
"data.add_data_frame(data_frame)"
"data.add_df(df)"
]
},
{
Expand Down
4 changes: 2 additions & 2 deletions docs/environments/bi/mode.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ Place the following code into a notebook cell in order to install `ipyvizzu`
details).

```
!pip install ipyvizzu -t "/tmp" > /dev/null 2>&1
!pip install ipyvizzu pandas -t "/tmp" > /dev/null 2>&1
```

## Sample
Expand All @@ -62,7 +62,7 @@ data = Data()
df = pd.read_csv(
"https://ipyvizzu.vizzuhq.com/latest/showcases/titanic/titanic.csv"
)
data.add_data_frame(df)
data.add_df(df)

chart.animate(data)

Expand Down
6 changes: 3 additions & 3 deletions docs/environments/ide/pycharm.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,15 +33,15 @@ details.
Run the following command in your command line

```sh
pip install ipyvizzu
pip install ipyvizzu pandas
```

or place the following code into a notebook cell in order to install `ipyvizzu`
(visit [Installation chapter](../../installation.md) for more options and
details).

```
!pip install ipyvizzu
!pip install ipyvizzu pandas
```

## Sample
Expand All @@ -68,7 +68,7 @@ data = Data()
df = pd.read_csv(
"https://ipyvizzu.vizzuhq.com/latest/showcases/titanic/titanic.csv"
)
data.add_data_frame(df)
data.add_df(df)

chart.animate(data)

Expand Down
6 changes: 3 additions & 3 deletions docs/environments/ide/vscode.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,15 +33,15 @@ details.
Run the following command in your command line

```sh
pip install ipyvizzu
pip install ipyvizzu pandas
```

or place the following code into a notebook cell in order to install `ipyvizzu`
(visit [Installation chapter](../../installation.md) for more options and
details).

```
!pip install ipyvizzu
!pip install ipyvizzu pandas
```

## Sample
Expand All @@ -68,7 +68,7 @@ data = Data()
df = pd.read_csv(
"https://ipyvizzu.vizzuhq.com/latest/showcases/titanic/titanic.csv"
)
data.add_data_frame(df)
data.add_df(df)

chart.animate(data)

Expand Down
4 changes: 2 additions & 2 deletions docs/environments/notebook/colab.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ Place the following code into a notebook cell in order to install `ipyvizzu`
details).

```
!pip install ipyvizzu
!pip install ipyvizzu pandas
```

## Sample
Expand All @@ -66,7 +66,7 @@ data = Data()
df = pd.read_csv(
"https://ipyvizzu.vizzuhq.com/latest/showcases/titanic/titanic.csv"
)
data.add_data_frame(df)
data.add_df(df)

chart.animate(data)

Expand Down
4 changes: 2 additions & 2 deletions docs/environments/notebook/databricks.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ Place the following code into a notebook cell in order to install `ipyvizzu`
details).

```
!pip install ipyvizzu
!pip install ipyvizzu pandas
```

## Sample
Expand All @@ -66,7 +66,7 @@ data = Data()
df = pd.read_csv(
"https://ipyvizzu.vizzuhq.com/latest/showcases/titanic/titanic.csv"
)
data.add_data_frame(df)
data.add_df(df)

chart.animate(data)

Expand Down
4 changes: 2 additions & 2 deletions docs/environments/notebook/datacamp.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ Place the following code into a notebook cell in order to install `ipyvizzu`
details).

```
!pip install ipyvizzu
!pip install ipyvizzu pandas
```

## Sample
Expand Down Expand Up @@ -67,7 +67,7 @@ data = Data()
df = pd.read_csv(
"https://ipyvizzu.vizzuhq.com/latest/showcases/titanic/titanic.csv"
)
data.add_data_frame(df)
data.add_df(df)
chart.animate(data)


Expand Down
4 changes: 2 additions & 2 deletions docs/environments/notebook/deepnote.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ Place the following code into a notebook cell in order to install `ipyvizzu`
details).

```
!pip install ipyvizzu
!pip install ipyvizzu pandas
```

## Sample
Expand All @@ -66,7 +66,7 @@ data = Data()
df = pd.read_csv(
"https://ipyvizzu.vizzuhq.com/latest/showcases/titanic/titanic.csv"
)
data.add_data_frame(df)
data.add_df(df)

chart.animate(data)

Expand Down
6 changes: 3 additions & 3 deletions docs/environments/notebook/jupyterlab.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,15 +33,15 @@ details.
Run the following command in your command line

```sh
pip install ipyvizzu
pip install ipyvizzu pandas
```

or place the following code into a notebook cell in order to install `ipyvizzu`
(visit [Installation chapter](../../installation.md) for more options and
details).

```
!pip install ipyvizzu
!pip install ipyvizzu pandas
```

## Sample
Expand Down Expand Up @@ -71,7 +71,7 @@ data = Data()
df = pd.read_csv(
"https://ipyvizzu.vizzuhq.com/latest/showcases/titanic/titanic.csv"
)
data.add_data_frame(df)
data.add_df(df)

chart.animate(data)

Expand Down
2 changes: 1 addition & 1 deletion docs/environments/notebook/jupyterlite.md
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ async def get_contents(path):
data = Data()
data_csv = await get_contents("titanic.csv")
df = pd.read_csv(StringIO(data_csv["content"]))
data.add_data_frame(df)
data.add_df(df)

chart.animate(data)

Expand Down
6 changes: 3 additions & 3 deletions docs/environments/notebook/jupyternotebook.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,15 +33,15 @@ details.
Run the following command in your command line

```sh
pip install ipyvizzu
pip install ipyvizzu pandas
```

or place the following code into a notebook cell in order to install `ipyvizzu`
(visit [Installation chapter](../../installation.md) for more options and
details).

```
!pip install ipyvizzu
!pip install ipyvizzu pandas
```

## Sample
Expand Down Expand Up @@ -71,7 +71,7 @@ data = Data()
df = pd.read_csv(
"https://ipyvizzu.vizzuhq.com/latest/showcases/titanic/titanic.csv"
)
data.add_data_frame(df)
data.add_df(df)

chart.animate(data)

Expand Down
4 changes: 2 additions & 2 deletions docs/environments/notebook/kaggle.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ Place the following code into a notebook cell in order to install `ipyvizzu`
details).

```
!pip install ipyvizzu
!pip install ipyvizzu pandas
```

## Sample
Expand Down Expand Up @@ -69,7 +69,7 @@ data = Data()
df = pd.read_csv(
"https://ipyvizzu.vizzuhq.com/latest/showcases/titanic/titanic.csv"
)
data.add_data_frame(df)
data.add_df(df)

chart.animate(data)

Expand Down
4 changes: 2 additions & 2 deletions docs/environments/notebook/noteable.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ Place the following code into a notebook cell in order to install `ipyvizzu`
details).

```
!pip install ipyvizzu
!pip install ipyvizzu pandas
```

## Sample
Expand Down Expand Up @@ -65,7 +65,7 @@ data = Data()
df = pd.read_csv(
"https://ipyvizzu.vizzuhq.com/latest/showcases/titanic/titanic.csv"
)
data.add_data_frame(df)
data.add_df(df)

chart.animate(data)

Expand Down
4 changes: 2 additions & 2 deletions docs/environments/platform/flask.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ Run the following command in your command line in order to install `ipyvizzu`
details).

```sh
pip install ipyvizzu flask
pip install ipyvizzu pandas flask
```

## Sample
Expand Down Expand Up @@ -66,7 +66,7 @@ data = Data()
df = pd.read_csv(
"https://ipyvizzu.vizzuhq.com/latest/showcases/titanic/titanic.csv"
)
data.add_data_frame(df)
data.add_df(df)

chart.animate(data)

Expand Down
2 changes: 1 addition & 1 deletion docs/environments/platform/mercury.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ data = Data()
df = pd.read_csv(
"https://ipyvizzu.vizzuhq.com/latest/showcases/titanic/titanic.csv"
)
data.add_data_frame(df)
data.add_df(df)

chart.animate(data)

Expand Down
4 changes: 2 additions & 2 deletions docs/environments/platform/panel.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ Run the following command in your command line in order to install `ipyvizzu`
details).

```sh
pip install ipyvizzu panel
pip install ipyvizzu pandas panel
```

## Sample
Expand Down Expand Up @@ -63,7 +63,7 @@ def create_chart():
df = pd.read_csv(
"https://ipyvizzu.vizzuhq.com/latest/showcases/titanic/titanic.csv"
)
data.add_data_frame(df)
data.add_df(df)

chart.animate(data)

Expand Down
4 changes: 2 additions & 2 deletions docs/environments/platform/streamlit.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ Run the following command in your command line in order to install `ipyvizzu`
details).

```sh
pip install ipyvizzu streamlit
pip install ipyvizzu pandas streamlit
```

## Sample
Expand Down Expand Up @@ -68,7 +68,7 @@ def create_chart():
df = pd.read_csv(
"https://ipyvizzu.vizzuhq.com/latest/showcases/titanic/titanic.csv"
)
data.add_data_frame(df)
data.add_df(df)

chart.animate(data)

Expand Down
6 changes: 3 additions & 3 deletions docs/environments/platform/voila.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,15 +33,15 @@ details.
Run the following command in your command line

```sh
pip install ipyvizzu voila
pip install ipyvizzu pandas voila
```

or place the following code into a notebook cell in order to install `ipyvizzu`
(visit [Installation chapter](../../installation.md) for more options and
details).

```
!pip install ipyvizzu
!pip install ipyvizzu pandas
```

## Sample
Expand Down Expand Up @@ -71,7 +71,7 @@ data = Data()
df = pd.read_csv(
"https://ipyvizzu.vizzuhq.com/latest/showcases/titanic/titanic.csv"
)
data.add_data_frame(df)
data.add_df(df)

chart.animate(data)

Expand Down
Loading