[Scilab-users] Reg :: Area Between two curves

Antoine Monmayrant amonmayr at laas.fr
Tue May 21 11:26:50 CEST 2013


 
Le Dimanche 19 Mai 2013 04.49 CEST, Rafael Guerra <jrafaelbguerra at hotmail.com> a écrit: 
 
> Hi Antoine,I have tried in Scilab 5.4 Win7 your 2-year old example script:  
> x=[-10:10];y1=x+10;y2=x.*x;   BetweenCurves(x,y1,y2);and got a in-between
> curve filling result that seams to "leak" (see attached picture):
> Scilab5p4_BetweenCurves.gif
> <http://mailinglists.scilab.org/file/n4026721/Scilab5p4_BetweenCurves.gif> 
> Do you know whether this is a function limitation or a Scilab 5.4's feature
> instead?Thanks and regards,Rafael G.

Hi,

It's a limitation of my function: I assume that one curve always stays above the other one.
I quickly wrote this function to plot a fit, the upper bound of the fit confidence interval and the lower bound of the fit confidence interval.
It is not designed for curves that cross each other.
You might get better results with my function by plotting BetweenCurves(x,min(y1,y2),max(y1,y2)).

Cheers,

Antoine
> 
> 
> 
> --
> View this message in context: http://mailinglists.scilab.org/Reg-Area-Between-two-curves-tp3393261p4026721.html
> Sent from the Scilab users - Mailing Lists Archives mailing list archive at Nabble.com. 
 
 
 




More information about the users mailing list