cbag_small_1_cons_avg_plot.tex 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. \documentclass{standalone}
  2. \usepackage{pgfplots}
  3. \usepgfplotslibrary{statistics}
  4. \begin{document}
  5. \begin{tikzpicture}
  6. \begin{axis}[title={Concurrent Bag N-1 Producer, 1 Consumer}, % Title of the graph
  7. xtick={2,4,8,16,32,64,128,256}, % The ticks on the x-axis
  8. xlabel={number of threads}, % Label of the x-axis
  9. ylabel={time in [ms]}, % Label of the y-axis
  10. legend style={
  11. at={(1.05,0.95)}, % Position of the legend anchor
  12. anchor=north west % The legend anchor
  13. }]
  14. % Each graph is added via \addplot and a .data file, and
  15. % add a legend entry for the previous graph.
  16. \addplot table {\DATAPATH/avg/time/smallbench_cbag_1_cons_100.data};
  17. \addlegendentry{100 items}
  18. \addplot table {\DATAPATH/avg/time/smallbench_cbag_1_cons_1000.data};
  19. \addlegendentry{1000 items}
  20. \addplot table {\DATAPATH/avg/time/smallbench_cbag_1_cons_10000.data};
  21. \addlegendentry{10000 items}
  22. \end{axis}
  23. \end{tikzpicture}
  24. \begin{tikzpicture}
  25. \begin{axis}[title={Concurrent Bag N-1 Producer, 1 Consumer}, % Title of the graph
  26. xtick={2,4,8,16,32,64,128,256}, % The ticks on the x-axis
  27. xlabel={number of threads}, % Label of the x-axis
  28. ylabel={throughput in [operations/s]}, % Label of the y-axis
  29. legend style={
  30. at={(1.05,0.95)}, % Position of the legend anchor
  31. anchor=north west % The legend anchor
  32. }]
  33. % Each graph is added via \addplot and a .data file, and
  34. % add a legend entry for the previous graph.
  35. \addplot table {\DATAPATH/avg/throughput/smallbench_cbag_1_cons_100.data};
  36. \addlegendentry{100 items}
  37. \addplot table {\DATAPATH/avg/throughput/smallbench_cbag_1_cons_1000.data};
  38. \addlegendentry{1000 items}
  39. \addplot table {\DATAPATH/avg/throughput/smallbench_cbag_1_cons_10000.data};
  40. \addlegendentry{10000 items}
  41. \end{axis}
  42. \end{tikzpicture}
  43. \end{document}