diff --git a/benchmarks/.nushell/commit/plot.nu b/benchmarks/.nushell/commit/plot.nu index 4e0726e95affd6b9538e2d509c9b2e43b1dd2c15..201f7d5dbd982be931eef0e905fce07032e94fd9 100644 --- a/benchmarks/.nushell/commit/plot.nu +++ b/benchmarks/.nushell/commit/plot.nu @@ -16,6 +16,29 @@ export def main [data: path, --save: path] { | group-by name --to-table | reject items.name | rename --column { group: "name", items: "points" } + | insert style.color {|it| + match $it.name { + "BLS12-381" => "tab:blue" + "PALLAS" => "tab:green" + "BN254" => "tab:orange" + "CP6-782" => "tab:olive" + "ED-MNT4-298" => "tab:pink" + "MNT4-753" => "tab:red" + _ => "tab:grey" + } + } + | insert style.line.marker.shape {|it| + match $it.name { + "BLS12-381" => "s" + "PALLAS" => "o" + "BN254" => "^" + "CP6-782" => "*" + "ED-MNT4-298" => "X" + "MNT4-753" => "d" + _ => null + } + } + | insert style.line.marker.size { 10 } | sort-by name let options = [ diff --git a/benchmarks/.nushell/setup/plot.nu b/benchmarks/.nushell/setup/plot.nu index 44e86de7f6636ac74e47347f44af9fe06e88d2de..351ea18df6b0bc533b4e4f35b89828cd0422cde8 100644 --- a/benchmarks/.nushell/setup/plot.nu +++ b/benchmarks/.nushell/setup/plot.nu @@ -21,6 +21,29 @@ export def main [data: path, --save: path] { | group-by name --to-table | reject items.name | rename --column { group: "name", items: "points" } + | insert style.color {|it| + match $it.name { + "BLS12-381" => "tab:blue" + "PALLAS" => "tab:green" + "BN254" => "tab:orange" + "CP6-782" => "tab:olive" + "ED-MNT4-298" => "tab:pink" + "MNT4-753" => "tab:red" + _ => "tab:grey" + } + } + | insert style.line.marker.shape {|it| + match $it.name { + "BLS12-381" => "s" + "PALLAS" => "o" + "BN254" => "^" + "CP6-782" => "*" + "ED-MNT4-298" => "X" + "MNT4-753" => "d" + _ => null + } + } + | insert style.line.marker.size { 10 } | sort-by name let options = [ diff --git a/benchmarks/README.md b/benchmarks/README.md index b35cb098a0a54a35918af49814bb4d3df17a9729..a99b6dfefc275509a650d30f6b944d6cc3b1639c 100644 --- a/benchmarks/README.md +++ b/benchmarks/README.md @@ -63,6 +63,29 @@ for graph in [ | rename --column { n: "x", mean: "y", stddev: "e" } | group-by name --to-table | rename --column { group: "name", items: "points" } + | insert style.color {|it| + match $it.name { + "BLS12-381" => "tab:blue" + "PALLAS" => "tab:green" + "BN254" => "tab:orange" + "CP6-782" => "tab:olive" + "ED-MNT4-298" => "tab:pink" + "MNT4-753" => "tab:red" + _ => "tab:grey" + } + } + | insert style.line.marker.shape {|it| + match $it.name { + "BLS12-381" => "s" + "PALLAS" => "o" + "BN254" => "^" + "CP6-782" => "*" + "ED-MNT4-298" => "X" + "MNT4-753" => "d" + _ => null + } + } + | insert style.line.marker.size { 10 } gplt plot ...[ --title $graph.title --x-label "n"