Skip to content

Commit

Permalink
add panelists plot
Browse files Browse the repository at this point in the history
cahange size and font of onboarding
  • Loading branch information
EmadAghaei committed Apr 23, 2020
1 parent fef55ce commit 3c3abad
Show file tree
Hide file tree
Showing 11 changed files with 204 additions and 165 deletions.
346 changes: 190 additions & 156 deletions DivergingPlot_Panelists.py

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion DivergingStackedBar_QOS.py
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,7 @@
)


chart =alt.Chart(source).mark_bar().encode(
chart =alt.Chart(source,width=600,height=300).mark_bar().encode(
x='percentage_start:Q',
x2='percentage_end:Q',
y=alt.Y('question:N', axis=y_axis),
Expand Down
11 changes: 6 additions & 5 deletions Onboarding.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,25 +15,26 @@
FirstLOCWidth = np.add(tutorial, training_task).tolist()
firstTaskWidth = np.add(first_loc, FirstLOCWidth).tolist()
# careful: notice "bottom" parameter became "left"

# plt.figure(figsize=(5,7))
p0 = plt.barh(participants, training_task, color="#ffa600")
p1 = plt.barh(participants, tutorial,left=training_task, color="#ff6361")
p2 = plt.barh(participants, first_loc, left=FirstLOCWidth, color="#58508d")
p3 = plt.barh(participants, first_task, left=firstTaskWidth, color="#003f5c")
# we also need to switch the labels 003f5c
plt.xlabel('Time in minutes')
plt.xlabel('Time in minutes', fontsize=12)
# plt.ylabel('Participants of controlled(Ci) and experimental(Ei) groups')
plt.legend((p0[0],p1[0], p2[0], p3[0]),
('Training task', '\n'.join(wrap('Beginning of session until starting the first task', 25)),
'\n'.join(wrap('Start first task/issue until writing first LOC', 25)),
'\n'.join(wrap('Start first task/issue until finishing it', 25))
))
plt.title('Onboarding time of control(Ci) and experimental(Ei) participants')
plt.subplots_adjust(left=0.15, right=0.96, top=0.95, bottom=0.1)
), fontsize=11)
plt.title( 'Onboarding time of control(Ci) and experimental(Ei) participants', fontsize=13)
plt.subplots_adjust(left=0.19, right=0.89, top=0.87, bottom=0.1)
# remove the frame

plt.gca().spines['right'].set_visible(False)
plt.gca().spines['top'].set_visible(False)
# plt.figure(figsize=(5,5))



Expand Down
2 changes: 1 addition & 1 deletion QOC.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
# plt.ylabel('Participants of controlled(Ci) and experimental(Ei) groups')
plt.legend((p1[0], p2[0],p3[0],p4[0],p5[0]), ('Poor', 'Fairs','Satisfactory','Very Good','Excellent'),loc='lower left',
bbox_to_anchor=(0,1.02,1, 0.2),mode='expand',ncol=5,borderaxespad=0)
plt.title('Quality of code by control (C) and experimental (E) groups',y=1.09)
plt.title('Quality of code of control (C) and experimental (E) groups',y=1.09)
plt.subplots_adjust(left=0.1, right=0.9, top=0.9, bottom=0.1)
plt.gca().spines['right'].set_visible(False)
plt.gca().spines['top'].set_visible(False)
Expand Down
6 changes: 4 additions & 2 deletions SVGtoPDF.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,7 @@
from reportlab.graphics import renderPDF, renderPM


drawing = svg2rlg("./data/visualization_1.svg")
renderPDF.drawToFile(drawing, "./data/QuestionVisualized.pdf")
drawing = svg2rlg("./data/Panelists.svg")
renderPDF.drawToFile(drawing, "./data/Panelists2.pdf")
# drawing = svg2rlg("./data/Qos.svg")
# renderPDF.drawToFile(drawing, "./data/Qos.pdf")
Binary file added data/Panelists.pdf
Binary file not shown.
1 change: 1 addition & 0 deletions data/Panelists.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added data/Panelists2.pdf
Binary file not shown.
Binary file added data/Qos.pdf
Binary file not shown.
1 change: 1 addition & 0 deletions data/Qos.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified data/onboading.pdf
Binary file not shown.

0 comments on commit 3c3abad

Please sign in to comment.