title: How to visualize slices of volumetric data in matplotlib just as in Matlab?
body: <p>How can the <a href="https://www.mathworks.com/help/matlab/ref/slice.html?s_tid=srchtitle_slice_1" rel="nofollow noreferrer">matlab function slice</a> be replicated in matplotlib?</p>
  <p>Consider the following piece of code from that page:</p>
  <pre><code>[X,Y,Z] = meshgrid(-2:.2:2);
  V = X.*exp(-X.^2-Y.^2-Z.^2);
  
  xslice = [-1.2,0.8,2];   
  yslice = [];
  zslice = 0;
  slice(X,Y,Z,V,xslice,yslice,zslice)
  </code></pre>
  <p>Please do not suggest any solutions that depend on vtk, mayavi etc as it seems that these cannot be installed on the system for reasons not important here.</p>