.. _sphx_glr_auto_examples_plot_evoked_data.py: .. _tut_plot_evoked: ===================== Visualize evoked data ===================== Here we'll generate some attention for pecularities of visualizing the HCP evoked outputs using MNE plotting functions. .. code-block:: python # Author: Denis A. Enegemann # License: BSD 3 clause import os.path as op import hcp from hcp import preprocessing as preproc we assume our data is inside a designated folder under $HOME .. code-block:: python storage_dir = op.expanduser('~/mne-hcp-data') hcp_path = op.join(storage_dir, 'HCP') recordings_path = op.join(storage_dir, 'hcp-meg') subjects_dir = op.join(storage_dir, 'hcp-subjects') subject = '105923' # our test subject data_type = 'task_working_memory' run_index = 0 Let's get the evoked data. .. code-block:: python hcp_evokeds = hcp.read_evokeds(onset='stim', subject=subject, data_type=data_type, hcp_path=hcp_path) for evoked in hcp_evokeds: if not evoked.comment == 'Wrkmem_LM-TIM-face_BT-diff_MODE-mag': continue .. rst-class:: sphx-glr-script-out Out:: Reading 4D PDF file /Users/dengemann/mne-hcp-data/HCP/105923/unprocessed/MEG/6-Wrkmem/4D/c,rfDC... Creating Neuromag info structure ... ... Setting channel info structure. ... no headshape file supplied, doing nothing. Currently direct inclusion of 4D weight tables is not supported. For critical use cases please take into account the MNE command "mne_create_comp_data" to include weights as printed out by the 4D "print_table" routine. In order to plot topographic patterns we need to transform the sensor positions to MNE coordinates one a copy of the data. We're not using this these transformed data for any source analyses. These take place in native BTI/4D coordinates. .. code-block:: python evoked_viz = evoked.copy() preproc.map_ch_coords_to_mne(evoked_viz) evoked_viz.plot_joint() .. image:: /auto_examples/images/sphx_glr_plot_evoked_data_001.png :align: center .. rst-class:: sphx-glr-script-out Out:: Could not find layout for all the channels. Generating custom layout from channel positions. Failed to locate mag channel positions from layout. Inferring channel positions from data. for subsequent analyses we would use `evoked` not `evoked_viz`. See also :ref:`tut_compute_inverse_erf` to see how the story continues. **Total running time of the script:** ( 0 minutes 4.500 seconds) .. container:: sphx-glr-download :download:`Download Python source code: plot_evoked_data.py ` .. container:: sphx-glr-download :download:`Download Jupyter notebook: plot_evoked_data.ipynb ` .. rst-class:: sphx-glr-signature `Generated by Sphinx-Gallery `_