update_layout ( title = "Population changes 1987 to 2007", width = 1000, height = 1000, showlegend = False, ) fig. scatter () to plot values and vary marker properties. Import pandas as pd import aph_objects as go from plotly import data df = data. Scatter ( mode = 'markers', x =, y =, opacity = 0.5, marker = dict ( color = 'LightSkyBlue', size = 80, line = dict ( color = 'MediumPurple', width = 8 ) ), showlegend = False ) ) fig. Scatter ( mode = 'markers', x = x2, y = y2, marker = dict ( color = 'LightSkyBlue', size = 20, line = dict ( color = 'MediumPurple', width = 2 ) ), name = 'Opacity 1.0' ) ) # Add trace with large markers fig. Scatter ( mode = 'markers', x = x, y = y, opacity = 0.5, marker = dict ( color = 'LightSkyBlue', size = 20, line = dict ( color = 'MediumPurple', width = 2 ) ), name = 'Opacity 0.5' ) ) # Add second scatter trace with medium sized markers # and opacity 1.0 fig. Figure () # Add first scatter trace with medium sized markers fig. uniform ( low = 4.5, high = 6, size = ( 500 ,)) # Build figure fig = go. These parameters control what visual semantics are used to identify the different subsets. The relationship between x and y can be shown for different subsets of the data using the hue, size, and style parameters. Import aph_objects as go # Generate example data import numpy as np x = np. Draw a scatter plot with possibility of several semantic groupings.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |