Plot mpg (on the y-axis) vs hp (on the x-axis) by color using p.circle().Use the figure() function to create a figure p with the x-axis labeled 'HP' and the y-axis labeled 'MPG'. Use the read_csv() function of pandas to read in 'auto.csv' and store it in the DataFrame df.Additionally, each glyph will be colored according to values in the color column. Your job is to plot miles-per-gallon ( mpg) vs horsepower ( hp) by passing Pandas column selections into the p.circle() function. The CSV file is provided for you as 'auto.csv'. In this example, you will read a CSV file containing information on 392 automobiles manufactured in the US, Europe and Asia from 1970 to 1982. You can create Bokeh plots from Pandas DataFrames by passing column selections to the glyph functions.īokeh can plot floating point numbers, integers, and datetime data types.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |