<div dir="ltr"><div><div><div>I should note, I created a modified Splitter (called CombinatorialSplitter), which returns the datasets that I want. The only edits are to lines 119 and 133 in <a href="https://github.com/PyMVPA/PyMVPA/blob/master/mvpa2/generators/splitters.py">splitters.py</a>:<br><br></div>119: <span class="">for</span> isplit, split <span class="">in</span> <span class="">enumerate</span>(cfgs): ---> for isplit, split in enumerate(itertools.combinations(cfgs,self.__combination_val)):<br>133: filter_ <span class="">=</span> splattr_data <span class="">==</span> split ----> filter_ = np.array([i in split for i in splattr_data])<br><br></div>My plan then is to run the analysis like so (each dataset has fa['network_ids'], with a number identifying each network; I haven't fully tested this yet):<br><br>splitter = CombinatorialSplitter('network_ids',25)<br>#clf, nf as normal<br>cv = CrossValidation(clf,nf,errorfx=corr_error,pass_attr=[('fa.network_ids','fa',1)])<br>res = []<br>for i in splitter.generate(ds):<br>    res.append(cv(i)<br>res_all = hstack(res)<br><br></div>Then res_all is 3 x 26 (3 runs, 26 because 26 c 1 = 26), with a separate row for each, column for each combination. and each column has fa.network_ids which identifies which networks were included. My plan was then to <font size="2">use the data to perform a calculation like I described in the last message.</font><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Dec 10, 2015 at 2:34 PM, Bill Broderick <span dir="ltr"><<a href="mailto:billbrod@gmail.com" target="_blank">billbrod@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div>Sorry, I realize my description of the problem wasn't very clear.<br><br>ds.summary() looks like this (after dropping the time points without targets):<br>Dataset: 54x26@float64, <sa: chunks,targets>, <fa: network_ids><br>stats: mean=0.0879673 std=1.08415 var=1.17538 min=-3.56651 max=4.62532<br>No details due to large number of targets or chunks. Increase maxc and maxt if desired<br>Summary for chunks across targets<br>  chunks  mean  std  min max #targets<br>    1    0.333 0.471  0   1     18<br>    2    0.333 0.471  0   1     18<br>    3    0.333 0.471  0   1     18<br>Number of unique targets > 20 thus no sequence statistics<br><br></div>"Volume for each volume" was a typo, I meant value for each volume. For this subject, the full dataset is 1452 x 26, where we have 1452 time points (across all runs) and 26 time courses. We then label each time point as with the reaction time if it happens during an event (we're regressing to the reaction time) or 'other' if it doesn't. We then are left with 54 time points, across 3 runs.<br><br></div>Re: Richard's comment, we're interested in problem 1: we want to evaluate the predictive power of each feature. We hypothesize that three of these time courses are much more important than the rest. Based on earlier work in the lab (<a href="https://www.sciencemag.org/content/337/6090/109.full" target="_blank">Carter et al. 2012</a>), I was thinking of using something similar to the Unique Combinatorial Performance (UCP) to evaluate the contribution of each time course. UCP was used for pairs of ROIs: For each ROI i, the UCP is the average additional classification accuracy observed when a model was constructed using data from i with a second ROI j (for every j). Since we're looking at individual time courses, I was thinking of looking at the difference in accuracies between analyses containing time course i and those not containing time course i (or those containing time courses i and j and those not containing time courses i and j, etc.). <br><br></div><div>Does that make sense? <br><br></div><div>I agree that feature selection methods don't seem appropriate here and something like what I outlined above seems intuitively appealing -- does it sound like a reasonable way to evaluate predictive power of each time course?<br><br></div><div>Thanks,<br></div><div>Bill<br></div></div><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="h5">On Wed, Dec 9, 2015 at 7:10 PM, Richard Dinga <span dir="ltr"><<a href="mailto:dinga92@gmail.com" target="_blank">dinga92@gmail.com</a>></span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5"><div dir="ltr"><span>Bill Broderick wrote:<br><br>> However, to determine which timecourse is contributing the most to the<br>> classifiers performance,<br><br></span><span>> see which timecourses or which combination<br>> of time courses caused the greatest drop in performance when removed.<br><br></span><span>I wrote:<br>> You might take a look at Relief algorithm (also implemented in PyMVPA),<br>> that is less hacky approach to your feature weighting problem.<br><br><br></span><span>Yaroslav Halchenko wrote:<br><br>> there is yet another black hole of methods to assess contribution of<br>> each feature to performance of the classifier.  The irelief, which was<br>> mentioned is one of them...<br><br></span><span>> So what is your classification performance if you just do<br>> classsification on all features?  which one could you obtain if you do<br>> feature selection, e.g. with SplitRFE (which would eliminate features to<br>> attain best performance within each cv folds in nested cv)<br><br><br></span>I think there are (at least) 2 separate problems. <br><br>1. How to evaluate predictive power for every feature in order to interpret data<br>2. How to evaluate importance of features for a classifier in order to understand a model and possibly select set of features to get best performance.<br><br>Feature selection methods like Lasso or RFE (as far as I know) would omit most of redundant/higly correlated features, therefore making a 1. impossible. It still might me a good idea for other reasons. </div>
<br></div></div><span class="">_______________________________________________<br>
Pkg-ExpPsy-PyMVPA mailing list<br>
<a href="mailto:Pkg-ExpPsy-PyMVPA@lists.alioth.debian.org" target="_blank">Pkg-ExpPsy-PyMVPA@lists.alioth.debian.org</a><br>
<a href="http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-exppsy-pymvpa" rel="noreferrer" target="_blank">http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-exppsy-pymvpa</a><br></span></blockquote></div><br></div>
</blockquote></div><br></div>