Examples of doubleW


Examples of org.netlib.util.doubleW

    int NPTS=10000,NBIN=101,NPNB=NPTS+NBIN;
    int n=0,k,nlim;
    double pi=acos(-1.0),sbeps;
    // Expected ave,adev,sdev,vrnce,skew,curt
    double expect[]={pi/2.0,pi/2.0-1.0,0.683667,0.467401,0.0,-0.806249};
    doubleW ave=new doubleW(0),adev = new doubleW(0);
    doubleW sdev=new doubleW(0),vrnce = new doubleW(0);
    doubleW skew=new doubleW(0),curt = new doubleW(0);
    double x;
    double[] temp=new double[NPNB],e=buildVector(expect);
    boolean localflag, globalflag=false;

   
View Full Code Here

Examples of org.netlib.util.doubleW

  }

  @Test
  public void test() {
    int i,k,ibin,NBINS=10,NPTS=10000;
    doubleW chsq=new doubleW(0),prob = new  doubleW(0),df =new doubleW(0);
    double x;
    double[] bins=new double[NBINS],ebins=new double[NBINS];
    boolean localflag=false,globalflag=false;

   
View Full Code Here

Examples of org.netlib.util.doubleW

    double[] bbb = buildVector(NP,1.0),xx = new double[NP];
    bbb[0]=3.0;
    bbb[NP-1] = -1.0;
    final int ITOL=1,ITMAX=75;
    final double TOL=1.0e-9;
    doubleW err = new doubleW(0);
    intW iter = new intW(0);

    TestLinbcg test = new TestLinbcg(sa);
    test.solve(bbb,xx,ITOL,TOL,ITMAX,iter,err);
View Full Code Here

Examples of org.netlib.util.doubleW

  // and its p-value as prob, small values of prob indicating that the arrays have significantly different means.
  // The data arrays are assumed to be drawn from populations with the same true variance.
  public static void ttest(final double[] data1, final double[] data2,
      final doubleW t, final doubleW prob){
    double svar,df;
    doubleW ave1 = new doubleW(0);
    doubleW ave2 = new doubleW(0);
    doubleW var1 = new doubleW(0);
    doubleW var2 = new doubleW(0);
   
    int n1=data1.length, n2=data2.length;
    avevar(data1,ave1,var1);
    avevar(data2,ave2,var2);
    df=n1+n2-2;
View Full Code Here

Examples of org.netlib.util.doubleW

  //  Given the arrays data1[0..n1-1] and data2[0..n2-1], this routine returns Student's t as t,
  //  and its p-value as prob, small values of prob indicating that the arrays have significantly different
  // means. The data arrays are allowed to be drawn from populations with unequal variances.
  public static void tutest(final double[] data1, final double[] data2,
      final doubleW t, final doubleW prob) {
    doubleW ave1 = new doubleW(0);
    doubleW ave2 = new doubleW(0);
    doubleW var1 = new doubleW(0);
    doubleW var2 = new doubleW(0);
    double df;
    int n1=data1.length, n2=data2.length;
    avevar(data1,ave1,var1);
    avevar(data2,ave2,var2);
    t.val=(ave1.val-ave2.val)/sqrt(var1.val/n1+var2.val/n2);
View Full Code Here

Examples of org.netlib.util.doubleW

  // Given the paired arrays data1[0..n-1] and data2[0..n-1], this routine returns Student's t for
  // paired data as t, and its p-value as prob, small values of prob indicating a significant difference of means
  public static void tptest(final double[] data1, final double[] data2,
      final doubleW t, final doubleW prob) {
    doubleW ave1 = new doubleW(0);
    doubleW ave2 = new doubleW(0);
    doubleW var1 = new doubleW(0);
    doubleW var2 = new doubleW(0);

    int j, n=data1.length;
    double sd,df,cov=0.0;
    avevar(data1,ave1,var1);
    avevar(data2,ave2,var2);
View Full Code Here

Examples of org.netlib.util.doubleW

  // Given the arrays data1[0..n1-1] and data2[0..n2-1], this routine returns the value of f,
  // and its p-value as prob. Small values of prob indicate that the two arrays have significantly
  // different variances.
  public static void ftest(final double[] data1, final double[] data2,
      final doubleW f, final doubleW prob) {
    doubleW ave1 = new doubleW(0);
    doubleW ave2 = new doubleW(0);
    doubleW var1 = new doubleW(0);
    doubleW var2 = new doubleW(0);

    double df1,df2;
    int n1=data1.length, n2=data2.length;
    avevar(data1,ave1,var1);
    avevar(data2,ave2,var2);
View Full Code Here

Examples of org.netlib.util.doubleW

  public static void spear(final double[] data1, final double[] data2,
      final doubleW d, final doubleW zd, final doubleW probd,
    final doubleW rs, final doubleW probrs) {
    int j,n=data1.length;
    double vard,t,fac,en3n,en,df,aved;
    doubleW sf = new doubleW(0);
    doubleW sg = new doubleW(0);
   
    double[] wksp1=new double[n],wksp2=new double[n];
    for (j=0;j<n;j++) {
      wksp1[j]=data1[j];
      wksp2[j]=data2[j];
View Full Code Here

Examples of org.netlib.util.doubleW

   */
  public static void ks2d1s(final double[] x1, final double[] y1, final QuadvlInf quadvl,
      final doubleW d1, final doubleW prob) {
    int j,n1=x1.length;
    double rr,sqen;
    doubleW dum = new doubleW(0);
    doubleW dumm = new doubleW(0);
    doubleW r1 = new doubleW(0);
   
    doubleW fa = new doubleW(0);
    doubleW fb = new doubleW(0);
    doubleW fc = new doubleW(0);
    doubleW fd = new doubleW(0);

    doubleW ga = new doubleW(0);
    doubleW gb = new doubleW(0);
    doubleW gc = new doubleW(0);
    doubleW gd = new doubleW(0);

    KSdist ks = new KSdist();
    d1.val=0.0;
    for (j=0;j<n1;j++) {
      quadct(x1[j],y1[j],x1,y1,fa,fb,fc,fd);
View Full Code Here

Examples of org.netlib.util.doubleW

   */
  
  public static void ks2d2s(final double[] x1, final double[] y1, final double[] x2, final double[] y2,
      final doubleW d, final doubleW prob) {
    int j,n1=x1.length,n2=x2.length;
    doubleW dum = new doubleW(0);
    doubleW dumm = new doubleW(0);
    doubleW r1 = new doubleW(0);
    doubleW r2 = new doubleW(0);
   
    doubleW fa = new doubleW(0);
    doubleW fb = new doubleW(0);
    doubleW fc = new doubleW(0);
    doubleW fd = new doubleW(0);

    doubleW ga = new doubleW(0);
    doubleW gb = new doubleW(0);
    doubleW gc = new doubleW(0);
    doubleW gd = new doubleW(0);

    double d1,d2,rr,sqen;
    KSdist ks = new KSdist();
    d1=0.0;
    for (j=0;j<n1;j++) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.