Skip to content

Commit a64f6b2

Browse files
committed
Merge pull request #119 from Eric89GXL/fix-flake
FIX: Fix new PEP8
2 parents b27896e + cd4d837 commit a64f6b2

22 files changed

+46
-48
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ clean-ctags:
2424
clean: clean-build clean-pyc clean-so clean-ctags
2525

2626
flake:
27-
if command -v flake8 > /dev/null; then \
27+
@if command -v flake8 > /dev/null; then \
2828
flake8 --count surfer examples; \
2929
fi
3030

examples/plot_basics.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@
55
Initialize a basic visualization session.
66
77
"""
8-
print(__doc__)
9-
108
from surfer import Brain
119

10+
print(__doc__)
11+
1212
"""
1313
Define the three important variables.
1414
Note that these are the first three positional arguments

examples/plot_fmri_activation.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,10 @@
88
file format that Nibabel can understand.
99
1010
"""
11+
from surfer import Brain
1112

1213
print(__doc__)
1314

14-
from surfer import Brain
15-
1615
"""
1716
Bring up the visualization window.
1817
"""

examples/plot_fmri_activation_volume.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,11 @@
1212
be imported from ``surfer.io``.
1313
1414
"""
15-
16-
print(__doc__)
17-
1815
import os
1916
from surfer import Brain, project_volume_data
2017

18+
print(__doc__)
19+
2120
"""
2221
Bring up the visualization window.
2322
"""

examples/plot_fmri_conjunction.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,13 @@
1010
with PySurfer.
1111
1212
"""
13-
14-
print(__doc__)
15-
1613
import os.path as op
1714
import numpy as np
1815
from surfer import io
1916
from surfer import Brain
2017

18+
print(__doc__)
19+
2120
"""
2221
Initialize the visualization.
2322
"""

examples/plot_foci.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,15 @@
77
according to coordinates or vertex ids.
88
99
"""
10-
print(__doc__)
11-
1210
import os
1311
import os.path as op
1412
from numpy import arange
1513
from numpy.random import permutation
1614
import nibabel as nib
1715
from surfer import Brain
1816

17+
print(__doc__)
18+
1919
subject_id = "fsaverage"
2020
subjects_dir = os.environ["SUBJECTS_DIR"]
2121

examples/plot_freesurfer_normalization.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@
1717
import nibabel as nib
1818
from surfer import Brain
1919

20+
print(__doc__)
21+
2022
brain = Brain("fsaverage", "both", "inflated")
2123

2224
for hemi in ["lh", "rh"]:

examples/plot_label.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@
66
with a large amount of control over the visual representation.
77
88
"""
9-
print(__doc__)
10-
119
import os
1210
from surfer import Brain
1311

12+
print(__doc__)
13+
1414
subject_id = "fsaverage"
1515
hemi = "lh"
1616
surf = "smoothwm"

examples/plot_label_foci.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@
77
that label and the focus that defines its center.
88
99
"""
10-
print(__doc__)
11-
1210
from surfer import Brain, utils
1311

12+
print(__doc__)
13+
1414
subject_id = "fsaverage"
1515

1616
"""

examples/plot_meg_inverse_solution.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,14 @@
55
Data were computed using mne-python (http://martinos.org/mne)
66
77
"""
8-
print(__doc__)
9-
108
import os
119
import numpy as np
1210

1311
from surfer import Brain
1412
from surfer.io import read_stc
1513

14+
print(__doc__)
15+
1616
"""
1717
define subject, surface and hemisphere(s) to plot
1818
"""
@@ -29,8 +29,8 @@
2929
read MNE dSPM inverse solution
3030
"""
3131
for hemi in ['lh', 'rh']:
32-
stc_fname = os.path.join('example_data/meg_source_estimate-'
33-
+ hemi + '.stc')
32+
stc_fname = os.path.join('example_data/meg_source_estimate-' +
33+
hemi + '.stc')
3434
stc = read_stc(stc_fname)
3535

3636
"""

0 commit comments

Comments
 (0)