![example picture for push_matrix()](/images/reference/Py5Graphics_push_matrix_0.png)

```python
def setup():
py5.size(100, 100, py5.P2D)
g = py5.create_graphics(60, 60, py5.P2D)
with g.begin_draw():
g.translate(30, 30)
with g.push_matrix():
g.scale(2)
with g.begin_closed_shape():
g.vertex(-10, -10)
g.vertex(10, -10)
g.vertex(10, 10)
g.vertex(-10, 10)
with g.begin_closed_shape():
g.vertex(-10, -10)
g.vertex(10, -10)
g.vertex(10, 10)
g.vertex(-10, 10)
py5.image(g, 0, 0)
py5.image(g, 25, 25)
```