You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
and is available for use in that environment as of June 2018.
17
17
18
-
What's New
19
-
----------
20
-
**Improved MultiIndex Support (as of 1.0.6-beta.6)**:
21
-
Qgrid now displays multi-indexed DataFrames with some of the index cells merged for readability, as is normally done when viewing DataFrames as a static html table. The following image shows qgrid displaying a multi-indexed DataFrame that was returned from Quantopian's `Pipeline API <https://www.quantopian.com/tutorials/pipeline?utm_source=github&utm_medium=web&utm_campaign=qgrid-repo>`_:
Qgrid has some new API methods which can be used to attach event handlers. Event handlers are callback methods that get called when certain events occur in the qgrid interface. In qgrid 1.0.3, event handlers can be attached with the ``on`` method and detached with the ``off`` method. There are ``on`` and ``off`` methods on both the ``qgrid`` module (see `qgrid.on <https://qgrid.readthedocs.io/en/latest/#qgrid.on>`_), and on individual QgridWidget instances (see `qgrid.QgridWidget.on <https://qgrid.readthedocs.io/en/latest/#qgrid.QgridWidget.on>`_).
30
-
31
-
To get a better idea of how these methods might be used, see the `Events API`_ section below.
32
-
33
18
Demo
34
19
----
35
20
Click the badge below to try out the latest beta of qgrid in Quantopian's hosted research environment. If you're already signed into Quantopian you'll be brought directly to the demo notebook. Otherwise you'll be prompted to register (it's free):
# only required if you have not added conda-forge to your channels yet
81
66
conda config --add channels conda-forge
82
-
67
+
83
68
conda install qgrid
84
69
85
70
Jupyterlab Installation
@@ -102,6 +87,40 @@ able to use qgrid in notebooks as you normally would.
102
87
having trouble, try installing those versions. Feel free to file an issue if you find that qgrid isn't working
103
88
with a newer version of either dependency.*
104
89
90
+
What's New
91
+
----------
92
+
**Column-specific options (as of 1.1.0)**:
93
+
Thanks to a significant `PR from the community <https://github.com/quantopian/qgrid/pull/191>`_, Qgrid users now have the ability to set a number of options on a per column basis. This allows you to do things like explicitly specify which column should be sortable, filterable, editable, etc. For example, if you wanted to prevent filtering on all columns except for a column named `'A'`, you could do the following::
See the updated `show_grid <https://qgrid.readthedocs.io/en/v1.1.0/#qgrid.show_grid>`_ documentation for more information.
100
+
101
+
**Disable editing on a per-row basis (as of 1.1.0)**:
102
+
This feature can be thought of as the first row-specific option that qgrid supports. In particular it allows a user to specify, using python code, whether or not a particular row should be editable. For example, to make it so only rows in the grid where the `'status'` column is set to `'active'` are editable, you might use the following code::
**New API methods for dynamically updating an existing qgrid widget (as of 1.1.0)**:
110
+
Adds the following new methods, which can be used to update the state of an existing Qgrid widget without having to call `show_grid` to completely rebuild the widget:
**Improved MultiIndex Support (as of 1.0.6-beta.6)**:
117
+
Qgrid now displays multi-indexed DataFrames with some of the index cells merged for readability, as is normally done when viewing DataFrames as a static html table. The following image shows qgrid displaying a multi-indexed DataFrame that was returned from Quantopian's `Pipeline API <https://www.quantopian.com/tutorials/pipeline?utm_source=github&utm_medium=web&utm_campaign=qgrid-repo>`_:
@@ -218,7 +237,7 @@ you open the ``index.html`` file in your browser, you should be able to preview
218
237
219
238
Events API
220
239
----------
221
-
As of qgrid 1.0.3 there are new ``on`` and ``off`` methods in qgrid which can be used to attach/detach event handlers. Previously the only way to listen for events was to use undocumented parts of the API.
240
+
As of qgrid 1.0.3 there are new ``on`` and ``off`` methods in qgrid which can be used to attach/detach event handlers. They're available on both the ``qgrid`` module (see `qgrid.on <https://qgrid.readthedocs.io/en/latest/#qgrid.on>`_), and on individual QgridWidget instances (see `qgrid.QgridWidget.on <https://qgrid.readthedocs.io/en/latest/#qgrid.QgridWidget.on>`_). Previously the only way to listen for events was to use undocumented parts of the API.
222
241
223
242
Having the ability to attach event handlers allows us to do some interesting things in terms of using qgrid in conjunction with other widgets/visualizations. One example is using qgrid to filter a DataFrame that's also being displayed by another visualization.
224
243
@@ -252,10 +271,10 @@ The first gif shows how you can use qgrid to filter the data that's being shown
252
271
:width:600px
253
272
254
273
A brief demo showing qgrid hooked up to a matplotlib plot
255
-
274
+
256
275
The second gif shows how you can move qgrid to a separate view in JupyterLab, which makes it more convenient
257
276
to use in conjunction with other visualizations (in this case, a couple of ``Output`` widgets):
0 commit comments