Back to the main page.

Bug 1137 - cellfun problem in sourcedescriptives

Status CLOSED FIXED
Reported 2011-11-10 16:19:00 +0100
Modified 2018-05-26 13:36:54 +0200
Product: FieldTrip
Component: core
Version: unspecified
Hardware: PC
Operating System: Windows
Importance: P1 normal
Assigned to: Stephen Whitmarsh
URL:
Tags:
Depends on:
Blocks:
See also:

Stephen Whitmarsh - 2011-11-10 16:19:57 +0100

I'm quite out of my depth here as to why exactly the following happens, and if its my fault(and problem) or not, but here it is anyway: I have sourcedata from pcc (from freqanalysis, method = 'fourier') which has mom and csd: source = csd: {1x21819 cell} noisecsd: {1x21819 cell} mom: {1x21819 cell} filter: {1x21819 cell} csdlabel: {'scandip' 'scandip' 'scandip'} Now I want to have pow values returned by sourcedescriptives. If I do the following: cfg = []; cfg.powmethod = 'regular'; cfg.keeptrials = 'yes'; source_temp{i} = ft_sourcedescriptives(cfg,source); I get the following error: the input is source data with 21819 positions computing singletrial voxel-level cross-spectral densities [--------------\] computing singletrial voxel-level power [-| ]??? Error using ==> cellfun Non-scalar in Uniform output, at index 1, output 1. Set 'UniformOutput' to false. Error in ==> ft_sourcedescriptives at 334 source.trial(triallop).pow(source.inside) = cellfun(powmethodfun, source.trial(triallop).csd(source.inside), dipselcell(source.inside)); 334 source.trial(triallop).pow(source.inside) = cellfun(powmethodfun, source.trial(triallop).csd(source.inside), dipselcell(source.inside)); I remember someone mentioning something about UniformOutput being a new matlab thing? In any case, it DOES work when I also use cfg.projectmom = 'yes'; See below Don't ask me why. What is does is a lot of computation and give me a mom I will remove again. As I see it, I already had a mom (and a csd for that matter). no mommie pun intended btw ;-) cfg = []; cfg.projectmom = 'yes'; cfg.powmethod = 'regular'; cfg.keeptrials = 'yes'; source_temp{i} = ft_sourcedescriptives(cfg,source); the input is source data with 21819 positions projecting dipole moment [-------------------------------------------------] computing singletrial voxel-level cross-spectral densities [--------------\] computing singletrial voxel-level power [---------------------------------\] the call to "ft_sourcedescriptives" took 116 seconds and an estimated 0 MB Cheers, Stephen


Boris Reuderink - 2011-11-17 10:46:43 +0100

Changed the status of bugs without a specific owner to UNCONFIRMED. I'll try to replicate these bugs (potentially involving the submitter), and change confirmed bugs to NEW. Boris


Boris Reuderink - 2011-11-17 13:39:20 +0100

Hi Stephen, Do you have a script to reproduce this error? I don't have the experience yet to reproduce this on my own. And, que the "yo moma" jokes... :). Best, Boris


Boris Reuderink - 2011-11-28 16:05:27 +0100

Bump.


Boris Reuderink - 2012-01-03 14:01:04 +0100

Bump.


Diego Lozano Soldevilla - 2013-02-13 13:42:14 +0100

is this still a bug?


Stephen Whitmarsh - 2018-05-26 13:36:54 +0200

It's been so long, and had so much fun with you since, that I won't be pressing charges. :) Closed the bug.