Skip to content

Conversation

@michaelbabyn
Copy link
Contributor

@michaelbabyn michaelbabyn commented Aug 19, 2018

This is the PR for updating the graphwidget documentation to plotly.py version 3's FigureWidget for this issue.

  • Interactive Data Analysis with ipywidgets
  • FigureWidget overview
  • Interact notebook
  • Create New Window with Jupyter Lab
  • Slider Widget with Plotly
  • Using Mouse Events with Plotly FigureWidget
  • Adding Zoom Effects
  • Hover Events
  • Click Events
  • add thumbnail gifs
@michaelbabyn michaelbabyn added the ReviewReady This PR is ready for review label Aug 30, 2018
@michaelbabyn michaelbabyn requested a review from Kully August 31, 2018 15:51
@Kully
Copy link
Contributor

Kully commented Sep 3, 2018

@michaelbabyn gonna have a look now

@Kully
Copy link
Contributor

Kully commented Sep 3, 2018

Overview

screen shot 2018-09-03 at 6 04 08 pm

You should combine this two code blocks and put the Create an empty figurewidget... markdown cell in the same markdown cell for the title:

i.e.

#### Create a Simple FigureWidget Create an empty figurewidget and then view it 
import plotly.graph_objs as go f= go.FigureWidget() f 

As a general rule, it is better to combine more code together, unless you specifically want to print multiple things in each code cell. An example of this is further down in the this doc:

screen shot 2018-09-03 at 6 08 23 pm

@michaelbabyn
Copy link
Contributor Author

@Kully , I'll go back through these and see what I can merge and I'll get rid of that superfluous output from updating the figureWidget but I think it makes sense to keep the updates separated to help demonstrate that each code block will instantly update the graph. See below for what I mean.

figurewidget-update

@Kully
Copy link
Contributor

Kully commented Sep 4, 2018

See below for what I mean.

no, you're absolutely right. I was a little unclear in my first comment. The second picture was demonstrating a Good use of small code chunks to show the functionality of adding different trace types.

… Jons notebooks as case studies to reflect that they are layed out differently
@Kully
Copy link
Contributor

Kully commented Sep 4, 2018

screen shot 2018-09-04 at 11 28 48 am

there should not be this much white space between the param and arg:

figure = go.Figure( data=data, layout=layout ) 
@Kully
Copy link
Contributor

Kully commented Sep 4, 2018

Jupyter Lab with FigureWidget

screen shot 2018-09-04 at 11 58 11 am

you're not your

@Kully
Copy link
Contributor

Kully commented Sep 4, 2018

Interact Decorator

screen shot 2018-09-04 at 3 58 55 pm

put a period at the end of this sentence


screen shot 2018-09-04 at 1 59 19 pm

You should put an empty chart in here


@Kully
Copy link
Contributor

Kully commented Sep 4, 2018

Slider Widget

Important note for all docs. The structure of our imports are like this:

# import import plotly ... ... from plotly import ... # non-plotly imports import ... 

See the scatter plot doc for an example of this.

screen shot 2018-09-04 at 4 07 37 pm


screen shot 2018-09-04 at 4 33 29 pm

PEP-8 - same comment from previous section:

widgets.FloatRangeSlider( min=xmin, max=xmax, step=(xmax - xmin) / 1000.0, ... ) 

Same comments for the rest of this doc.

@Kully
Copy link
Contributor

Kully commented Sep 4, 2018

DashShader Case Study

period at the end of sentence:

screen shot 2018-09-04 at 4 58 43 pm


Combine these 3 cells together

screen shot 2018-09-04 at 4 37 50 pm


same here:

screen shot 2018-09-04 at 4 53 51 pm

@Kully
Copy link
Contributor

Kully commented Sep 4, 2018

Click Events

separate the imports as explained above

*Short and Sweet - very good 👍

@Kully
Copy link
Contributor

Kully commented Sep 4, 2018

Selection Events

  • separate the imports here too
  • add a brief description after the title about what the doc is doing.

Car Exploration

The Load cars dataset should not be so big. It should be an header4 (4 #s in markdown):

#### Load cars dataset

and Cars dataset exploration with plotly.py version 3.0 should not be an empty section like that as it shows up in the sidebar like a normal section.

screen shot 2018-09-04 at 5 10 00 pm


this cell needs to be run. the image is not showing up in the doc

screen shot 2018-09-04 at 5 09 56 pm


same comment about collecting import lines together

there is no output under fig. Do you have an image/GIF of what the fig should look like here?

screen shot 2018-09-04 at 5 12 23 pm


Notice Quantization section should not be its own section. The Notice Quantization and Apply Jitter sections should be one section. I suggest using Apply Jitter as the section title and then writing a little description underneath that says something like "Notice that the data values are quantized. We can apply jitter to the scatter points to get a better sense of how many there are..." etc


Again, Looking for Outliers is a blank section.

screen shot 2018-09-04 at 5 18 26 pm


All headers should be h4s

eg.
### Section Title

Bringing it all together is not h4.

@michaelbabyn
Copy link
Contributor Author

@Kully , I made the changes you mentioned in all but the "case study" docs (since those are just Jon's with GIFs to show off the widget and I think it makes sense to leave them as they are). So I think this should be good to merge. What do you think?

@Kully
Copy link
Contributor

Kully commented Sep 13, 2018

@michaelbabyn It looks like you did at least some of the grammar edits, but my comments about the headers in Car Exploration are still not addressed.

Send me a message if you are confused about what I am asking and I can clarify.

@jackparmer
Copy link
Contributor

jackparmer commented Sep 19, 2018

@michaelbabyn @cldougl People are still sharing the old GraphWidget-
https://twitter.com/elenamdata/status/1042148777782665216
When are these new replacement docs using FigureWidget going to be merged? We're creating a lot of confusion IMO with v3 using FigureWidget but the docs using GraphWidget which is basically deprecated

@michaelbabyn
Copy link
Contributor Author

I think they can be merged ASAP, @Kully wasn't sure if we should keep one of Jon's docs in there as is since it is quite different stylistically from the rest of the docs but that's all that's blocking.

@jackparmer
Copy link
Contributor

... wasn't sure if we should keep one of Jon's docs in there as is since it is quite different stylistically from the rest of the docs but that's all that's blocking.

Yeah, we shouldn't let that hold this up. Please merge & deploy today with either Jon's doc or a modified version that is more stylistically similar.

@cldougl
Copy link
Member

cldougl commented Sep 20, 2018

@jackparmer I told michael to wait until this could be reviewed before merging. @michaelbabyn feel free to merge now and we can deal with the styling later

@michaelbabyn michaelbabyn merged commit c687343 into source-design-merge Sep 20, 2018
@jonmmease
Copy link
Contributor

Has this been deployed yet? I'm still seeing the old GraphWidget stuff in the "Custom Controls with JavaScript" section.

screen shot 2018-09-23 at 6 55 39 am

Thanks for all your work on this @michaelbabyn!

@michaelbabyn michaelbabyn deleted the figure_widget_update branch September 19, 2019 17:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ReviewReady This PR is ready for review

6 participants