[Eeglablist] Plotting standard error with std_plotcurve

Arnaud Delorme arno at ucsd.edu
Thu Apr 11 22:24:12 PDT 2013


Dear Pete,

I have tried the following code and it worked for me (it plots shaded areas).

cuealpha11 = rand(101,31);
cuealpha31 = rand(101,31);
cuealpha13 = rand(101,31);
cuetimes = linspace(-100, 600, 101);
std_plotcurve(cuetimes, {cuealpha11; cuealpha13; cuealpha31}, 'plotconditions', 'together', 'plotstderr', 'on', 'figure', 'on');

The configuration where it does not work is when cuealpha11; cuealpha13; cuealpha31 have different sizes.
Best,

Arno

On 8 Apr 2013, at 10:02, Pete Manza wrote:

> 
> Hi all,
> 
> I'm trying to plot a curveplot with the standard error shaded in around the lines.  I got this to work once a while back with std_plotcurve but now I keep getting errors.
> 
> The help page for std_plotcurve says the plotstderr function only works under some data configurations, but I'm not sure what else to do.  
> 
> I'm plotting three conditions (cuealpha11, cuealpha13, cuealpha31) that have a 101x31 structure (31 subjects).  The times for the x-axis are in a 101x1 structure.
> 
> When I run this command:
> 
> std_plotcurve(cuetimes, {cuealpha11; cuealpha13; cuealpha31}, 'plotconditions', 'together', 'plotstderr', 'on', 'figure', 'on');
> 
> I gut the following error message:
> 
> ??? Error using ==> fill
> Vectors must be the same lengths.
> 
> Error in ==> fillcurves at 65
>     h = fill(allpointsx, allpointsy, color);
> 
> Error in ==> std_plotcurve at 390
>                             hold on; chandle = fillcurves( allx,
>                             tmpdata(tmpi,:)-tmpstd(tmpi,:),
>                             tmpdata(tmpi,:)+tmpstd(tmpi,:), tmpcol{tmpi}); hold on;
> 
> 
> 
> What data structure does this need?  The plots for the curves come out just fine, but I can't get the standard error shading.
> Thanks very much,
> Pete Manza
> Stony Brook University
> _______________________________________________
> Eeglablist page: http://sccn.ucsd.edu/eeglab/eeglabmail.html
> To unsubscribe, send an empty email to eeglablist-unsubscribe at sccn.ucsd.edu
> For digest mode, send an email with the subject "set digest mime" to eeglablist-request at sccn.ucsd.edu

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://sccn.ucsd.edu/pipermail/eeglablist/attachments/20130411/0b0f87de/attachment.html>


More information about the eeglablist mailing list