MCPcopy Create free account
hub / github.com/cpmech/plotpy / grid_and_labels

Method grid_and_labels

src/plot.rs:308–319  ·  view source on GitHub ↗

Adds grid and labels

(&mut self, xlabel: &str, ylabel: &str)

Source from the content-addressed store, hash-verified

306
307 /// Adds grid and labels
308 pub fn grid_and_labels(&mut self, xlabel: &str, ylabel: &str) -> &mut Self {
309 write!(
310 &mut self.buffer,
311 "plt.gca().set_axisbelow(True)\n\
312 plt.grid(linestyle='--',color='grey',zorder=-1000)\n\
313 plt.gca().set_xlabel(r'{}')\n\
314 plt.gca().set_ylabel(r'{}')\n",
315 xlabel, ylabel
316 )
317 .unwrap();
318 self
319 }
320
321 /// Adds grid, labels, and legend
322 pub fn grid_labels_legend(&mut self, xlabel: &str, ylabel: &str) -> &mut Self {

Callers 15

grid_functions_workFunction · 0.80
test_slope_icon_belowFunction · 0.80
test_slope_icon_aboveFunction · 0.80
test_slope_icon_exampleFunction · 0.80
test_dark_mode_defaultFunction · 0.80
test_dark_mode_mochaFunction · 0.80
test_dark_mode_nordicFunction · 0.80

Calls

no outgoing calls

Tested by 15

grid_functions_workFunction · 0.64
test_slope_icon_belowFunction · 0.64
test_slope_icon_aboveFunction · 0.64
test_slope_icon_exampleFunction · 0.64
test_dark_mode_defaultFunction · 0.64
test_dark_mode_mochaFunction · 0.64
test_dark_mode_nordicFunction · 0.64