summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCoprDistGit <infra@openeuler.org>2023-05-15 05:39:41 +0000
committerCoprDistGit <infra@openeuler.org>2023-05-15 05:39:41 +0000
commitdfbc8c005cf169152a521fd485a58a800a4722ad (patch)
tree44c82e32a416136f5e9d76ccb9a5fb35f6cef3db
parent88319be583144e2440e732876909549d3fc86e4b (diff)
automatic import of python-pandas-explode
-rw-r--r--.gitignore1
-rw-r--r--python-pandas-explode.spec276
-rw-r--r--sources1
3 files changed, 278 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore
index e69de29..3b43eff 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/pandas_explode-0.0.7.tar.gz
diff --git a/python-pandas-explode.spec b/python-pandas-explode.spec
new file mode 100644
index 0000000..b25f425
--- /dev/null
+++ b/python-pandas-explode.spec
@@ -0,0 +1,276 @@
+%global _empty_manifest_terminate_build 0
+Name: python-pandas-explode
+Version: 0.0.7
+Release: 1
+Summary: Explode utility for Pandas dataframes (similar to UNNEST or explode)
+License: MIT
+URL: https://github.com/orenovadia/pandas_explode
+Source0: https://mirrors.nju.edu.cn/pypi/web/packages/0c/b9/979555fcb95a2396c8a61ff92e87c7030320c24a62fc4af28d5512cf9669/pandas_explode-0.0.7.tar.gz
+BuildArch: noarch
+
+
+%description
+[![Build Status](https://travis-ci.org/orenovadia/pandas_explode.svg?branch=master)](https://travis-ci.org/orenovadia/pandas_explode)
+
+# pandas_explode
+
+author: Oren Ovadia
+
+## Overview
+
+Explode utility for Pandas dataframes (similar to `UNNEST` or `explode`)
+
+
+## Examples
+
+```python
+import pandas as pd
+import pandas_explode
+pandas_explode.patch() # adds a `df.explode` method to all DataFrames
+
+df = pd.DataFrame({'s': ['a', 'b', 'c'], 'values': [[1, 2], [3, 4, 5], []]})
+df
+# s values
+# 0 a [1, 2]
+# 1 b [3, 4, 5]
+# 2 c []
+df.explode('values')
+# s values
+# 0 a 1
+# 0 a 2
+# 1 b 3
+# 1 b 4
+# 1 b 5
+
+df = pd.DataFrame({'s': ['a', 'b', 'c'], 'values': [{'col1': 1, 'col2': 2}, {'col1': 10, 'col3': 20}, {'col2': 2}]})
+df
+# s values
+# 0 a {'col1': 1, 'col2': 2}
+# 1 b {'col1': 10, 'col3': 20}
+# 2 c {'col2': 2}
+df.explode('values', axis=1)
+# s col1 col2 col3
+# 0 a 1.0 2.0 NaN
+# 1 b 10.0 NaN 20.0
+# 2 c NaN 2.0 NaN
+df.explode('values', axis=1, record_prefix=True)
+# s values.col1 values.col2 values.col3
+# 0 a 1.0 2.0 NaN
+# 1 b 10.0 NaN 20.0
+# 2 c NaN 2.0 NaN
+
+```
+
+
+## Installation / Usage
+
+To install use pip:
+
+ $ pip install pandas_explode
+
+
+Or clone the repo:
+
+ $ git clone https://github.com/orenovadia/pandas_explode.git
+ $ python setup.py install
+
+
+## Publishing
+
+ $ ./publish.sh
+
+
+%package -n python3-pandas-explode
+Summary: Explode utility for Pandas dataframes (similar to UNNEST or explode)
+Provides: python-pandas-explode
+BuildRequires: python3-devel
+BuildRequires: python3-setuptools
+BuildRequires: python3-pip
+%description -n python3-pandas-explode
+[![Build Status](https://travis-ci.org/orenovadia/pandas_explode.svg?branch=master)](https://travis-ci.org/orenovadia/pandas_explode)
+
+# pandas_explode
+
+author: Oren Ovadia
+
+## Overview
+
+Explode utility for Pandas dataframes (similar to `UNNEST` or `explode`)
+
+
+## Examples
+
+```python
+import pandas as pd
+import pandas_explode
+pandas_explode.patch() # adds a `df.explode` method to all DataFrames
+
+df = pd.DataFrame({'s': ['a', 'b', 'c'], 'values': [[1, 2], [3, 4, 5], []]})
+df
+# s values
+# 0 a [1, 2]
+# 1 b [3, 4, 5]
+# 2 c []
+df.explode('values')
+# s values
+# 0 a 1
+# 0 a 2
+# 1 b 3
+# 1 b 4
+# 1 b 5
+
+df = pd.DataFrame({'s': ['a', 'b', 'c'], 'values': [{'col1': 1, 'col2': 2}, {'col1': 10, 'col3': 20}, {'col2': 2}]})
+df
+# s values
+# 0 a {'col1': 1, 'col2': 2}
+# 1 b {'col1': 10, 'col3': 20}
+# 2 c {'col2': 2}
+df.explode('values', axis=1)
+# s col1 col2 col3
+# 0 a 1.0 2.0 NaN
+# 1 b 10.0 NaN 20.0
+# 2 c NaN 2.0 NaN
+df.explode('values', axis=1, record_prefix=True)
+# s values.col1 values.col2 values.col3
+# 0 a 1.0 2.0 NaN
+# 1 b 10.0 NaN 20.0
+# 2 c NaN 2.0 NaN
+
+```
+
+
+## Installation / Usage
+
+To install use pip:
+
+ $ pip install pandas_explode
+
+
+Or clone the repo:
+
+ $ git clone https://github.com/orenovadia/pandas_explode.git
+ $ python setup.py install
+
+
+## Publishing
+
+ $ ./publish.sh
+
+
+%package help
+Summary: Development documents and examples for pandas-explode
+Provides: python3-pandas-explode-doc
+%description help
+[![Build Status](https://travis-ci.org/orenovadia/pandas_explode.svg?branch=master)](https://travis-ci.org/orenovadia/pandas_explode)
+
+# pandas_explode
+
+author: Oren Ovadia
+
+## Overview
+
+Explode utility for Pandas dataframes (similar to `UNNEST` or `explode`)
+
+
+## Examples
+
+```python
+import pandas as pd
+import pandas_explode
+pandas_explode.patch() # adds a `df.explode` method to all DataFrames
+
+df = pd.DataFrame({'s': ['a', 'b', 'c'], 'values': [[1, 2], [3, 4, 5], []]})
+df
+# s values
+# 0 a [1, 2]
+# 1 b [3, 4, 5]
+# 2 c []
+df.explode('values')
+# s values
+# 0 a 1
+# 0 a 2
+# 1 b 3
+# 1 b 4
+# 1 b 5
+
+df = pd.DataFrame({'s': ['a', 'b', 'c'], 'values': [{'col1': 1, 'col2': 2}, {'col1': 10, 'col3': 20}, {'col2': 2}]})
+df
+# s values
+# 0 a {'col1': 1, 'col2': 2}
+# 1 b {'col1': 10, 'col3': 20}
+# 2 c {'col2': 2}
+df.explode('values', axis=1)
+# s col1 col2 col3
+# 0 a 1.0 2.0 NaN
+# 1 b 10.0 NaN 20.0
+# 2 c NaN 2.0 NaN
+df.explode('values', axis=1, record_prefix=True)
+# s values.col1 values.col2 values.col3
+# 0 a 1.0 2.0 NaN
+# 1 b 10.0 NaN 20.0
+# 2 c NaN 2.0 NaN
+
+```
+
+
+## Installation / Usage
+
+To install use pip:
+
+ $ pip install pandas_explode
+
+
+Or clone the repo:
+
+ $ git clone https://github.com/orenovadia/pandas_explode.git
+ $ python setup.py install
+
+
+## Publishing
+
+ $ ./publish.sh
+
+
+%prep
+%autosetup -n pandas-explode-0.0.7
+
+%build
+%py3_build
+
+%install
+%py3_install
+install -d -m755 %{buildroot}/%{_pkgdocdir}
+if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi
+if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi
+if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi
+if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi
+pushd %{buildroot}
+if [ -d usr/lib ]; then
+ find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/lib64 ]; then
+ find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/bin ]; then
+ find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/sbin ]; then
+ find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+touch doclist.lst
+if [ -d usr/share/man ]; then
+ find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst
+fi
+popd
+mv %{buildroot}/filelist.lst .
+mv %{buildroot}/doclist.lst .
+
+%files -n python3-pandas-explode -f filelist.lst
+%dir %{python3_sitelib}/*
+
+%files help -f doclist.lst
+%{_docdir}/*
+
+%changelog
+* Mon May 15 2023 Python_Bot <Python_Bot@openeuler.org> - 0.0.7-1
+- Package Spec generated
diff --git a/sources b/sources
new file mode 100644
index 0000000..2483f4d
--- /dev/null
+++ b/sources
@@ -0,0 +1 @@
+8c0246779099752003758dd51e580f8d pandas_explode-0.0.7.tar.gz