# Plotting spatialdata in only one coordinate system

**URL:** <https://discourse.scverse.org/t/plotting-spatialdata-in-only-one-coordinate-system/1419>\
**Category:** Ecosystem\
**Created:** [May 12, 2023, 3:16am UTC](https://discourse.scverse.org/t/plotting-spatialdata-in-only-one-coordinate-system/1419 "2023-05-12T03:16:42Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![conradfoo](https://avatars.discourse-cdn.com/v4/letter/c/b4bc9f/32.png) [@conradfoo](https://discourse.scverse.org/u/conradfoo)\
**Post date:** [May 12, 2023, 3:16am UTC](https://discourse.scverse.org/t/plotting-spatialdata-in-only-one-coordinate-system/1419/1 "2023-05-12T03:16:42Z")

</div>

Hi all,

I am trying to work with some CosMX data using the spatialdata package, but I’m having some trouble with plotting. I want to plot 1 FOV with several layers overlaid on top, but I don’t want to plot both the global and local (within FOV) coordinate system.

If I try to select an element using the `render_images` subroutine, I get an error that the number of elements doesn’t match the number of coordinate systems. How do I specify to only plot images within a specific coordinate system?

Thanks!

---

<div class="post-metadata">

**Author:** ![conradfoo](https://avatars.discourse-cdn.com/v4/letter/c/b4bc9f/32.png) [@conradfoo](https://discourse.scverse.org/u/conradfoo)\
**Post date:** [May 12, 2023, 8:28am UTC](https://discourse.scverse.org/t/plotting-spatialdata-in-only-one-coordinate-system/1419/2 "2023-05-12T08:28:42Z")

</div>

OK figured it out - if I run `transform_to_coordinate_system`, the resulting object should render properly in that coordinate system.

---

<div class="post-metadata">

**Author:** ![LucaMarconato](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.scverse.org/lucamarconato/32/661_2.png) [@LucaMarconato](https://discourse.scverse.org/u/LucaMarconato)\
**Post date:** [May 15, 2023, 11:15pm UTC](https://discourse.scverse.org/t/plotting-spatialdata-in-only-one-coordinate-system/1419/3 "2023-05-15T23:15:12Z")

</div>

Hi @conradfoo, sorry for the late answer and glad that you find a solution. Another alternative isn to call `sdata.pp.get_elements("local")`, which will filter the `SpatialData` object to the coordinate system you are interested to. You can see an example of this in action in this notebook: [Technology focus: MibiTOF — spatialdata](https://spatialdata.scverse.org/en/latest/tutorials/notebooks/notebooks/examples/technology_mibitof.html)
