<s> """<STR_LIT>""" <EOL> import matplotlib . pyplot as plt <EOL> import mne <EOL> from mne import io <EOL> from mne . datasets import sample <EOL> from mne . minimum_norm import read_inverse_operator , source_band_induced_power <EOL> print ( __doc__ ) <EOL> data_path = sample . data_path ( ) <EOL> raw_fname = data_path + '<STR_LIT>' <EOL> fname_inv = data_path + '<STR_LIT>' <EOL> tmin , tmax , event_id = - <NUM_LIT> , <NUM_LIT:0.5> , <NUM_LIT:1> <EOL> raw = io . read_raw_fif ( raw_fname ) <EOL> events = mne . find_events ( raw , stim_channel = '<STR_LIT>' ) <EOL> inverse_operator = read_inverse_operator ( fname_inv ) <EOL> include = [ ] <EOL> raw . info [ '<STR_LIT>' ] += [ '<STR_LIT>' , '<STR_LIT>' ] <EOL> picks = mne . pick_types ( raw . info , meg = True , eeg = False , eog = True , <EOL> stim = False , include = include , exclude = '<STR_LIT>' ) <EOL> event_id = <NUM_LIT:1> <EOL> events = events [ : <NUM_LIT:10> ] <EOL> epochs = mne . Epochs ( raw , events , event_id , tmin , tmax , picks = picks , <EOL> baseline = ( None , <NUM_LIT:0> ) , reject = dict ( grad = <NUM_LIT> , eog = <NUM_LIT> ) , <EOL> preload = True , detrend = <NUM_LIT:1> ) <EOL> bands = dict ( alpha = [ <NUM_LIT:9> , <NUM_LIT:11> ] , beta = [ <NUM_LIT> , <NUM_LIT> ] ) <EOL> stcs = source_band_induced_power ( epochs , inverse_operator , bands , n_cycles = <NUM_LIT:2> , <EOL> use_fft = False , n_jobs = <NUM_LIT:1> ) <EOL> for b , stc in stcs . iteritems ( ) : <EOL> stc . save ( '<STR_LIT>' % b ) <EOL> plt . plot ( stcs [ '<STR_LIT>' ] . times , stcs [ '<STR_LIT>' ] . data . mean ( axis = <NUM_LIT:0> ) , label = '<STR_LIT>' ) <EOL> plt . plot ( stcs [ '<STR_LIT>' ] . times , stcs [ '<STR_LIT>' ] . data . mean ( axis = <NUM_LIT:0> ) , label = '<STR_LIT>' ) <EOL> plt . xlabel ( '<STR_LIT>' ) <EOL> plt . ylabel ( '<STR_LIT>' ) <EOL> plt . legend ( ) <EOL> plt . title ( '<STR_LIT>' ) <EOL> plt . show ( ) </s>
