The line you are setting is the location of the x-y coordinate system, which is independent of the size of the canvas.
Set all the margins to zero and then they will match.
![Map5](https://communitybucketdatagraph.s3.us-east-2.amazonaws.com/community/datagraph/4258/afticqmlhef2i5cwrl5f29tpz8fseaus.png)
I find it helpful to continue to draw the x and y axes to see that they are scaled correctly (assuming you are overlaying some data).
![Map7](https://communitybucketdatagraph.s3.us-east-2.amazonaws.com/community/datagraph/4258/u7qe6mten31701uipj09x1xcc6qaehat.png)
The axis labels are not exported with the figure as they are outside of the range.
FYI — One shortcut is to create a graph for composition. That creates a canvas with the margins already set to zero.
![Map6](https://communitybucketdatagraph.s3.us-east-2.amazonaws.com/community/datagraph/4258/rvtdcb4la0ir70oknacwwsy5gnqpyjpj.png)