MCPcopy Create free account
hub / github.com/alandefreitas/matplotplusplus / x_end_point

Method x_end_point

source/matplot/axes_objects/bars.cpp:132–142  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

130 }
131
132 double bars::x_end_point(size_t cluster_index, size_t i) {
133 // get the x_value (automatic or manual)
134 double x_value = x_.size() > i ? x_[i] : i + 1;
135 // go to point where bar width starts
136 x_value -= bar_width_ / 2;
137 // advance according to the group index
138 x_value += range_for_cluster() * cluster_index;
139 // center
140 x_value += range_for_cluster() / 2;
141 return x_value;
142 }
143
144 std::string bars::data_string() {
145 std::stringstream ss;

Callers 1

mainFunction · 0.80

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected