enter image description here
Lets say I have multiple csv files for test_suites UPT_Synergy_graph22.csv, UPT_C7000_graph22.csv, SAT-Synergy-gen2_graph22.csv, like this i have 10 more csv files, which are having the same columns in all the files -build_id and pass percent. I need to plot the line graph for all those files. where build id is x-axis and pass-percent is y-axis. I need to get line graph for each csv file (mean for each test suite).
I was able to get the graph for only one csv file, i am not able to fetch the results for all.
please help me to resolve this. below is the code i have used. or suggest me with any other module that can fit.
import pandas as pd
import pygal
from pygal.style import Style
data_frame=pd.read_csv('C:\\Users\\shivarad\\Documents\\Scale_graph22.csv', dtype={"Pass
Percentage":int,"original_pass_percent":int})
a = []
b = []
line_chart=pygal.Line()
#line_chart.title='Graphical Representation of the pass percentage for a build ID---TEST SUITE: SCALE'
line_chart.x_labels=data_frame['build ID']
for index,row in data_frame.iterrows():
a.append(row["Pass Percentage"])
b.append(row["original_pass_percent"])
line_chart.add("Pass Percentage",a)
line_chart.add("original_pass_percent",b)
line_chart.render_in_browser()
#bar_chart.title='Graphical Representation of the pass percentage for a build ID---TEST SUITE: SCALE'
bar_chart = pygal.stackedBar(height=360, width=440,explicit_size=True)
bar_chart.title='Graphical Representation of the pass percentage for a build ID---TEST SUITE: SCALE'
bar_chart.x_labels=data_frame['build ID']
for index,row in data_frame.iterrows():
a.append(row["Pass Percentage"])
b.append(row["original_pass_percent"])
# adding the apeended list
bar_chart.add('Pass Percentage', a)
bar_chart.add('original_pass_percent', b)
# rendering the file
bar_chart.render_in_browser()}