Adding a graph to a layout with a different size than that of the graph.

I have a graph (actually, it's an image plot) that, before adding to a layout, has an absolute size of 256 x 256 pixels. I would like to add it to a layout, but at a size of 128 x 128 pixels. When I add it, the size remains at 256 x 256. Evidently the fact that the graph has an absolute size of 256 x 256 overrules the size specification on the layout.

If the size of the graph is set by "auto", then it can be added to a layout at any size. But if I then change the graph size to absolute, it also changes in the layout.

This may be the intended behavior, but it seems like the size setting in the layout should overrule the size setting in the graph, whether that setting is absolute or auto.

Is there a way to have an absolute-sized graph with a different size in a layout?

It is the intended behavior.

One solution for you is to create the graph window with an absolute size of 128 x 128, add it to the layout, and then expand the graph window by 2x by executing:

ModifyGraph expand=2