Example #1
0
def test_plot_scatter_files_mask():
    fns = glob(pjoin(pymvpa_dataroot,
                     *('haxby2001/sub001/anatomy/lowres00*.nii.gz'.split('/'))))
    # figure out reasonable threshold
    data = _get_data(fns[0])
    min_, max_ = np.min(data), np.max(data)
    plot_scatter_files(fns, mask_file=fns[0], mask_thresholds=(min_ + max_)/2.,
                       masked_opacity=0.5)
    # now fancier ones
    thrs = [min_ + (max_ - min_) * 0.2, min_ + (max_ - min_) * 0.8]
    plot_scatter_files(fns, mask_file=fns[0], mask_thresholds=thrs,
                       masked_opacity=0.5)

    plot_scatter_files(fns, mask_file=fns[0], mask_thresholds=thrs[::-1],
                       masked_opacity=0.5)
    pl.close('all')
Example #2
0
def test_plot_scatter_files_mask():
    fns = glob(pjoin(pymvpa_dataroot,
                     *('haxby2001/sub001/anatomy/lowres00*.nii.gz'.split('/'))))
    # figure out reasonable threshold
    data = _get_data(fns[0])
    min_, max_ = np.min(data), np.max(data)
    plot_scatter_files(fns, mask_file=fns[0], mask_thresholds=(min_ + max_)/2.,
                       masked_opacity=0.5)
    # now fancier ones
    thrs = [min_ + (max_ - min_) * 0.2, min_ + (max_ - min_) * 0.8]
    plot_scatter_files(fns, mask_file=fns[0], mask_thresholds=thrs,
                       masked_opacity=0.5)

    plot_scatter_files(fns, mask_file=fns[0], mask_thresholds=thrs[::-1],
                       masked_opacity=0.5)
    pl.close('all')
def test_get_data():
    fn = pjoin(pymvpa_dataroot,
               *('haxby2001/sub001/anatomy/lowres001.nii.gz'.split('/')))

    data = _get_data(fn)
    assert_true(data.ndim, 3)
Example #4
0
def test_get_data():
    fn = pjoin(pymvpa_dataroot,
               *('haxby2001/sub001/anatomy/lowres001.nii.gz'.split('/')))

    data = _get_data(fn)
    assert_true(data.ndim, 3)