0% found this document useful (0 votes)
230 views2 pages

Plotly Cheat Sheet

The document defines a scatter trace with x and y values of [1, 2, 3] and marker properties including color set to ['red', 'blue', 'green'] and size set to [30, 80, 200]. It then plots this trace using Plotly Express' iplot function to display the scatter plot.

Uploaded by

koolawais
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
230 views2 pages

Plotly Cheat Sheet

The document defines a scatter trace with x and y values of [1, 2, 3] and marker properties including color set to ['red', 'blue', 'green'] and size set to [30, 80, 200]. It then plots this trace using Plotly Express' iplot function to display the scatter plot.

Uploaded by

koolawais
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

trace = go.

Scatter (
x = [ 1, 2, 3 ] , y = [ 1, 2, 3 ] ,
marker = dict (
color = [ ‘red’, ‘blue’ ,
‘green’ ]
size = [ 30, 80, 200 ] ) ,
mode = ‘markers’ )
py.iplot ( [ trace ] )

In the terminal:
plot_url = py.plot ( fig )

Or in the IPython notebook:


py.iplot ( fig )
trace = dict (
type = ‘scattergeo’ ,
lon = [ 100, 400 ] , lat = [ 0, 0] ,
marker = dict (
marker = [ ‘red’, ‘blue’ ]
size = [ 30, 50 ] ) ,
mode = ‘markers’ )
py.iplot ( [ trace ] )

You might also like