Hi,
Thanks for the detailed reply - and for replying to the list, it helps a lot.
> % here I average the betas over the sessions
>
> for z=1:n_event_types
> a=[beta_values_raw(z)];
> for y=1:run_length-1
> a=[a, beta_values_raw(z+beta_to_beta*y)];
> end
> b=mean(a);
> beta_mean{z}={['con', num2str(z),' - mean beta-value'];b};
> end
Looks good to me
> % here I extract % signal change, which is not extracted per session but
> averaged over all sessions (as far as I know)
>
> for e_t = 1:n_event_types
> dur = 0;
> pct_ev(e_t) = event_signal(E, ets(e_t).e_spec, dur);
> end
This may well be your problem, caused by a lack of proper
documentation by me. I am fairly sure that the 'ets' variable will
have the events ordered (alphabetically) by name. This may well not
be the same as the order in the design. You can check this by doing
this:
[ets, names] = event_types_named(E);
and looking at the names. I'm afraid you will have to resort the ets
indices according to their place in the design matrix to get the same
order as for the betas.
Best,
Matthew
|