I have the following code:
\draw[step=1.0,black,thin] (0.5,0.5) grid (5.5,4.5);
which I would like to have generate grid lines in the Y direction at y = {0.5, 1.5, 2.5, 3.5, 4.5} and grid lines in the X direction at x = {0.5, 1.5, 2.5, 3.5, 4.5, 5.5}.
However, I get grid lines at y = {1.0, 2.0, 3.0, 4.0} and x = {1.0, 2.0, 3.0, 4.0, 5.0} with half cells around the edges of the grid. So instead of having a closed uniform grid, I get one with open edges and two half cells at the borders.
Does anybody know why it doesn't honor the starting point and stride?

(startx, starty) grid (endx, endy)basically define the clipping region whereas in order to shift it we need to use thexshiftyshiftthat you mentioned. It seems so counterintuitive to me that it is so much 'centered' around the origin (I do find it convenient though, it's just surprising). I was trying to find the grid shift parameters in the TikZ documentation for thegridcommand and found nothing. – Andrey Surovtsev Jun 19 '22 at 19:47xshiftandyshiftare used throughout to shift the coordinate system, it is convienient to use the same options for shifting grids. I agree that when starting out there is a lot to take in withTikZ, but once you use it for a while things get easier, at least the basics. – Peter Grill Jun 19 '22 at 21:26