# Embed mne.Viz.Brain.plot in pyqt5

**URL:** <https://mne.discourse.group/t/embed-mne-viz-brain-plot-in-pyqt5/6741>\
**Category:** Support & Discussions\
**Tags:** visualization\
**Created:** [April 18, 2023, 12:45pm UTC](https://mne.discourse.group/t/embed-mne-viz-brain-plot-in-pyqt5/6741 "2023-04-18T12:45:51Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![ZezeBrock](https://avatars.discourse-cdn.com/v4/letter/z/d2c977/32.png) [@ZezeBrock](https://mne.discourse.group/u/ZezeBrock)\
**Post date:** [April 18, 2023, 12:45pm UTC](https://mne.discourse.group/t/embed-mne-viz-brain-plot-in-pyqt5/6741/1 "2023-04-18T12:45:51Z")

</div>

- MNE version: e.g. 1.2.1
- operating system: e.g. Windows 10

\*\*surfer\_kwargs = dict(surface=‘inflated’, hemi=‘lh’, subjects\_dir=subjects\_dir,  
time\_viewer=False, views=‘lateral’, show\_traces=False)  
brain = stc.plot(\*\*surfer\_kwargs)

```
    # Create a FigureCanvas object
    self.canvas = FigureCanvas(brain)

    # Set the FigureCanvas as the central widget
    self.setCentralWidget(self.canvas)

```

\*\*  
Hello everyone hope you are well. I have been working on a visualization tool using PyQT5. With this said, I would like to embed the source estimates plot. Altough, I was able to embeed when the backend is matplotlib, I would prefer to do this with the plot generated by the pyvistaqt backend. Is there anyway to perform this?

Thank you in advance,  
Best regards all,

Pedro Gomes
