AnalysisCustomPlotΒΆ

from eureqa import Eureqa
from eureqa.analysis_cards import Plot

eureqa = Eureqa('http://localhost:10002', user_name='root', password='Changeme1', verbose=False)
analysis = eureqa.create_analysis('Example Analysis')
plot = Plot('First Title')
plot.plot([1,2,3], [4,5,6], color='blue', line_width=3, legend_label='Label 1')
plot.plot([11,22,33], [44,55,66], style='o', legend_label='Label 2', color='red', circle_radius=7)
plot.plot([10,11,12], [13,14,15], line_width=5, color='orange')
plot_card = analysis.create_plot_card(plot, 'First Card Title', 'This is the first card description.')
datasource = eureqa.create_data_source('data_source_1', 'tests/Nutrition.csv')
plot2 = Plot('Second Title', width='500px', height='500px', x_axis_label='x axis label', y_axis_label='y axis label')
plot2.plot('<row>', 'Calories', datasource=datasource, style='-o', line_width=3, circle_radius=5, color='blue', legend_label='Calories')
plot2.plot('<row>', '30*(Fat (g))', datasource=datasource, style='-o', line_width=3, circle_radius=5, color='red', legend_label='30*(Fat (g))')
plot_card_2 = analysis.create_plot_card(plot2, 'Second Card Title', 'This is the second card description')